In order to return a value from a VB.NET function one can assign a value to the "Functions Name" or use "return value."
I sometimes see these inter-mixed in the same function. Personally, I prefer the return.
My question is, what is the internal difference, if any, between the two?
...
Here is the scenario: I have two asp pages. a.aspx is layout and b.aspx is content. I want to display the contents of b.aspx inside a <div> on a.aspx. I know with PHP you can do it like so:
//a.php
<html>
<head>
<title>test</title>
</head>
<body>
<?PHP
include "b.php";
?>
</body>
</html>
//b.ph...
I have a WinForms app with a datagridview and a bindingsource. I want the user to confirm changes before I save them to the database.
I don't want to pop up the confirmation dialog unless I know the user has made changes. So I need a way to check if changes have been made. Any suggestions?
...
I have no intention of using "My" for anything in any of my projects. I haven't done anything with it (that I know of). But every one of class libraries shows a "My" namespace in Reflector and NDepend. This adds a lot of unnecessary clutter.
1) Why does it show up?
2) How can I remove it?
...
I've started to use a Vista machine for development. In case it is significant: I'm using MSBee so that I can code in the Visual Studio 2005 IDE while still building against the 1.1 framework.
On the Vista machine, when I tried to build a particular vb project, I got this error:
error BC30464: Namespace or type
'Compatibility' in...
Hello,
Is it possible to do CAD/CAM software without having to use C++? My company developed their software with c/C++ but that was more than 10 years ago. Today,there is a lot of legacy code that switching would force us to get rid of but i was wondering what the actual risks are. We have a lot of mathematical algorithms for toolpath c...
I'm helping a colleague develop a "catch all" type error handler for some controls his application. What he wants to do is pass the object that has the error, and the type of that object, such a TextBox or ComboBox, and then call the DirectCast method within his handler to properly address the Text attribute within it. In general, the me...
Is there any way to determine if a text file is currently open in a text editor? Or better yet, is there a way to trigger an event when a text file is opened (from any program)?
...
While for the most part you can generate the same MSIL, there are definitely differences in tooling. PEX, for example, works much easier with C#.
What Microsoft or 3rd party tools don't work equally well for both languages?
...
I have a VB.NET MDI WinForms app. My users have been complaining about form creep (as they call it), this is where each time you open a specific form within the main MDI window it opens slightly below and to the right of the location it loaded previously - i.e. it starts in the top left of the window and works its way down to the bottom ...
Hi, The following code is visual basic, .NET, ASP... all of the above?
Can anybody tell me what these two "Regex.Replace" functions/methods will leave me with when "strCookies" is equal to the block of text below the two Regex.Replace functions? I believe the idea is simply to capture the "sessionid" code and then the "cadata" code with ...
EDIT: duplicate of http://stackoverflow.com/questions/352882/why-is-there-such-a-large-percentage-of-c-questions
I couldn't help but notice that the tag topic count for C# is in excess of 8900 while the vb.net tag topic count is sitting at 1019. Does this mean that there is a shift towards c# as a .net language of choice, or perhaps the...
I see a lot of programs where if the text doesn't fit inside the bounds of the control, you can put your mouse over the control and the tooltip text will show you the full unclipped text, and also the tooltip text lines up completly with the text in the control.
I'm trying to do that with a combobox in VB 2005 (.net version 2.0). In th...
I have a VB.NET application and use some third party (closed source) ActiveX controls. One of the controls represents a "camera" (connected over several interfaces) and I try to write an example how to work with several cameras in one application. To do this I allocate multiple "camera" objects dynamically as an array which works as expe...
I can get the program to easily, upon startup, look for updates and then install them.
I want to have a button that the user can click that will check/install updates. Is this possible, if so how?
Edit: Sorry all, not ASP.NET; VB.NET only
...
I am learning Silverlight and WPF on my own to expand my programming base. I am following this tutorial, and I am currently stuck on part 3. I am up to the point where my application requests and receives a response from digg.com, but I cannot figure out how to properly dimension the XDocument class (as the tutorial shows) to read the x...
I have a VB.NET program that I wish to to publish. In the code it references a HTML page that I created. Instead of having the URL hard coded (example: www.test2.com/folder/index.html)
I would like to have it relative to wherever the encoder is installed to (example: /folder/index.html)
How can I do this?
Thanks!
...
I have the need to express simple conditionals as program input. The input must be human readable.
Is XML suited for this?
For example, I have the following conditional statement:
If AnimalType = Leopard And (SourceCountry = Kenya Or TargetCountry = Kenya) Then
ZooKeeper=Jack
Else
ZooKeeper=Jill
End If
Expressing the above ...
Is there a VB.net equivalent to the C#:
public string FirstName { get; set; }
I know you can do
Public Property name() As String
Get
Return _name.ToString
End Get
Set(ByVal value As String)
_name = value
End Set
End Property
But I can't seem to google up an answer on a vb shorthand.
...
I have created a shared add-in in Visual Studio 2008 and using the shared
add-in wizard and am coding in VB. When run the add in in Access 2003 I want
to check if the user has a database open, so I set a AccessApplication
variable to be the application object in the OnConnection procedure and then
on a button click I check if Access...