Difference Between VbNullString And Sting.Empty/""
Mar 13, 2009Anybody knows what the difference is?
View 5 RepliesAnybody knows what the difference is?
View 5 RepliesWhat is the difference between ErrorProvider.Clear() and ErrorProvider.SetError(tBox,vbNullString)
Is there a preference for one or the other?
Convert Dataset to Dictionary(of Sting,List(of sting)). My Dataset is like below..[code]...
View 1 RepliesI'm working on a blackjack card game but i can't convert the resulting string into an image.
Imports BlackJackLib.Class1
Public Class Form1
Dim oBlackJackLib As New BlackJackLib.Class1
[Code]....
Also is there an easier way to check for a card that is dealt twice?
This problem I guess is easy to solve for an "RegEx" master :P
My string look like this:
"name":"stefanACM".id...
"name":"test1".id...
"name":"test2".id...
So I need RegEx to get only names from sting (stefanACM,test1,test2). That means I need RegEx to find string between "name":" and ".id
i'm stuck on something so easy, i've googled, tired various methods but cant get it to work. Imagine if you can, i have an array (set as a string type) but the second slot holds a numebr that i want, e.g. 2333.
So to grab it i use the following code, however as my sport array is set to a string it wont allow it. Like i said i have tried a few ways but nothing works. Such a stupid and simple situation. I'm much much better with actionscript surely its just a string to int conversion?
i connect the datagrid to database using wizard ..... now the connection string is in config.app.. it has a password and user to access to database .. i have login form that the user should enter the username and the password for database ... how i can join the usertext.text wand passtext.text (textboxs) with the connection string in config.app ??by default is root, root, .. but it will change and i cant modify the application every time for change the connection string ?
View 1 Repliesstring which is obtained from a webservice that I would like to display in a textbox. The problem is the existing string is in HTML format so when I place it in the textbox it still has all the <Tags> etc. Is there a way to parse this text or would I be best to use the webbrowser tool? (I want to stick
with a textbox if I can)
All of a sudden, my form is giving an error on the form1.text Error 53 Value of type 'String' cannot be converted to 'System.Windows.Forms.ToolBarButton'.
vs 2008 shows it occurrs in the InitializeComponent:
Me.Name = "Form1"
Me.Text = "MyForm"
I dont know but I must of unknowingly changed something and now I cant put text in the form header?
the VB .net experts. I added the following code and I get an error as shown below.
[CODE]....
This is my first time working with VB, though I've been working with VBA for a couple years now to automate office routines at my work. At my last job, I saved about 3 hours a day with my automations, and at my current job, I'm shooting for about the same. The problem is, though I have a high affinity for computers and technology, I never studied to be a programmer, and so I really can only tweak code I find online, and then eventually build up enough of my own subroutines to accomplish the tasks at hand. This is why I'm posting here on this forum, I've reached my wits end for what I imagine is a relatively simple problem. This was initially written in VB 6, but I imported and converted it with Visual Studio 2008, and it runs fine. This demo code is set to populate a PDFwith some sample string text. What I want to do is to replace the string text with a reference to data in either an Access or SQL database - I prefer Access, but either will work. Here is a sample of the demo code I'm working with:
[code]...
On this last line, I want to replace the "1" sting text with a reference to a temporary 1-row table I'll be generating from an Access Query, with Field Names to match the Form Field names of the PDF, So I've setup an Access DB with the following configuration (in reference to the path, I'm using Vista x64):
[code]...
I have also imported this table as a dataset (my understanding is that the import into Visual Studio 2008 makes it a typed dataset?) so either referencing the access DB directly or the imported Dataset should work. I can also setup the Access DB as a SQL DB instead if it would make it easier. Now, if I was programming in VBA, I might do something like this:
[code]...
I am trying to test certain cell values to see if they contain subtrings of a certain format at the END of the cell sting value.E.G.I have cells with the values...
324f5
346-ssth
4565-Q1-09
dsfsd46
[code].....
I want to run a macro that searches through the cells and tests to see if they have a substring sitting at the end of the value that is in the format "-Q[number]-[number][number]" OR "-[3 LETTER MONTH ABBREVIATION][number]-[number][number]" OR "-[3 LETTER MONTH ABBREVIATION][number][number]-[number][number]"and then if the test is true, the cell color is changed to RED.So if I ran the macro on the example I gave above, it would turn the cells with the following values red:
4565-Q1-09
454354-FEB2-09
546-5-MAR03-09
I can do all the VB side of things but I don't know Regex but know it would help. I'm in a bit of a rush to finish this job for work because I finish working here in 2 days and need to get it done before I leave!
I have a DataGridView that has some columns with dates. It binds to an in-memory Datatable which gets loaded from an string array of data passed back from the backend Some of the rows returned have nulls for the date columns. Solution 1: If I define the Date column in the DataTable as "string" I can easily convert those nulls to empty strings and display it in the grid as empty strings (desired results). However, if the user clicks on the date column header to sort by date, it doesn't order the rows as you want. You get a purely string sort order. Not acceptable
[Code]...
This must've have been asked before but I couldn't locate it. In a mixed code project (VB and C#) we were debugging some old Visual Basic code where a statement as follows could be found:
If Request.Params("xxx") <> "" Then
'do something
I considered this a bug as Request.Params could be null, in which case the statement would've become false which wasn't the idea. So I thought. I just found out, -- probably for the tenth time and I will keep forgetting -- that the following two statements are not equal, while Nothing in VB should be equal to null in C# (thought I):
if(String.Empty == null) // always false
If String.Empty = Nothing Then ' always true
Should I dismiss this as a typical Microsoft backward compatibility effort, or should I consider this a huge error in the VB.NET compiler? Does anybody know the Microsoftean opinion on this oddity?
I have a array of strings and I am looping through them, but the string might be empty so I am trying this:
[Code]...
I'm sure this is straightforward but I cannot find the correct string to get a google result. In VB.NET what is the difference between = (equals sign) and := (colon followed by equals sign)?
View 3 Repliescan anyone tell me book for VB.net for beginner and complee package of books important for VB. as i don't know anything abt VB.
what is difference between VB.net and asp.net and c#??
Possible Duplicate: What are the most important functional differences between C# and VB.NET? What are the basic difference between c# and VB.net?
View 3 Repliesknow the difference between C#.Net and VB.Net. I use C#.Net for my projects, but when ever I met with some other programmers they often called VB.Net more powerful and easy, than C#.Net. I always asked them "Why it is more powerful then C#, since it uses the same framework?" but still I didn't get any answers.
View 3 Replieswhat exactly distinguishes a COM component from a DLL? Isn't a COM component just a library of functions that can be called from another application? Why is using a COM component so much more complicated than just registering it like one would do with a DLL?
View 4 RepliesI'm looking for an explanation of the difference between
Dim sw1 = New StringWriter()
Dim sw2 As New StringWriter()
Both seem to instantiate new string writer instances that I can use.
I was under the assumption that VB's For Each loop was the same as a For Next loop. But when i try running the following code I do not get the expected result.
[Code]...
I have this code, first I thougt it should be the same but i cant acces the info in the same way .. why is this???
Dim tp(,) As Integer = {{1, 3, 5, 9, 7}, {34, 3, 4, 5, 6}}
Dim tpo(1)() As Integer
tpo(0) = New Integer() {1, 3, 5, 9, 7}
[code].....
The first one I use only one for each and the other one I use two .. why is this different? are noy they 2 dimensional arrays ???
What is the difference between VB and VB.NET?
explanation with examples preferred
The next code works fine in C#:
[Code]...
But this code crash with a OverflowException in VB.Net.
[Code]...
Both codes seems the same to me. What is the difference and how can I get the C# code converted to VB.Net?
For those who have experience, working with VB.NET, it's easier to use SlimDX or SDL? The tutorials for SlimDX are already written for .NET, but I've read that SDL it's a lot easier than DirectX itself.in my case, I just need 2D graphics.
View 4 RepliesI have two arraylists, and I would like to have a new arraylist with only the uncommon items. Is this the "best" or at least decent way to do it?
[Code]...
[Code].....
What is the major difference between 'for each' and 'for' loops in .NET? Is there any performance gain while comparing these two? Which one gives a better performance/faster/memory management?
I have in the past used .net executables as libraries. I'd just add them to the references in visual studio and I was ready to go. Today I tried the same to a new exe (actually mine) and it doesn't seem to work. When I add it to Visual Studio and try to watch its members on the Object Browser, it doesn't show up anything inside that executable's assembly.
I know the main difference between an exe and dll is that the first has an entry point while the 2nd doesn't. Are there any more differences? I know that unmanaged dll's also have a DLL entry point, do .net have one too?Also, what might be the reasons that could make my standard exe/dll (with this i mean, not obfuscated or anything extreme like that) not show up anything in the Object Browser?
What's the difference between / and for division in vb.net? My code gives very different answers depending on which I use. I've seen both before, but never knew the difference.
View 3 Replies