[RESOLVED] Array from VB6 to VB.Net
Hi All,
I got one issue to ask you guys.
Here is a code in my VB6 application.
Array(1,"P11","@P 100", "NEXT")
However, now I'm converting this program to VB.Net and I'm stuck at this point.
Can't find Array(xxx,xxx,xxx) in VB.Net 2010.
Is there any option or function for this?
Thanks.
scsfdev
Re: Array from VB6 to VB.Net
This syntax is supported in VB 2010:
vb.net Code:
Dim myArray = {"element1", "element2"}
Another option, which is also supported by older versions, is:
vb.net Code:
Dim myArray As String() = New String() {"element1", "element2"}
Re: Array from VB6 to VB.Net
Quote:
Originally Posted by
jmcilhinney
This syntax is supported in VB 2010:
vb.net Code:
Dim myArray = {"element1", "element2"}
Another option, which is also supported by older versions, is:
vb.net Code:
Dim myArray As String() = New String() {"element1", "element2"}
Hi jmcilhinney,
Thanks for your info. :thumb: