R
Riffrafter
Hi All,
Been away from programming for a while and just d/l'd the trial version of
VS10 Pro and am playing around in VB.
I've noticed more than a few differences between VB6 and VB10. That's OK
though...we must evolve right?
Here a few very basic things that have me stumped. I've looked in the
documentation, but the examples are more "technical" than I think the
answers call for. I'm hoping someone can help.
I have a bunch of labels on a form that I want to write thru while iterating
thru a loop. In VB6 this was easy with Control arrays. For example:
For X = 1 to 6
Label(x).caption = x
Next
In addition to not having a caption property (it's .text now), how do I
easily reference a label without having to type them all out each time?
That can be very cumbersome.
The Array.sort method looks very promising. I've written more sort routines
than I care to remember and don't mind never doing it again. But I'm having
trouble figuring out the correct syntax to sort an array of "type" Structure
that has two elements, and the value I want to sort on is the second
element. For example:
public structure someData
number as integer
biggernumber as long
end structure
dim Ratspatoot (100) as someData
Need to sort Ratspatoot using the value in Ratspatoot.biggernumber. This
one is probably very simple and I'm just missing something somehow.
Thanks in advance.
Been away from programming for a while and just d/l'd the trial version of
VS10 Pro and am playing around in VB.
I've noticed more than a few differences between VB6 and VB10. That's OK
though...we must evolve right?
Here a few very basic things that have me stumped. I've looked in the
documentation, but the examples are more "technical" than I think the
answers call for. I'm hoping someone can help.
I have a bunch of labels on a form that I want to write thru while iterating
thru a loop. In VB6 this was easy with Control arrays. For example:
For X = 1 to 6
Label(x).caption = x
Next
In addition to not having a caption property (it's .text now), how do I
easily reference a label without having to type them all out each time?
That can be very cumbersome.
The Array.sort method looks very promising. I've written more sort routines
than I care to remember and don't mind never doing it again. But I'm having
trouble figuring out the correct syntax to sort an array of "type" Structure
that has two elements, and the value I want to sort on is the second
element. For example:
public structure someData
number as integer
biggernumber as long
end structure
dim Ratspatoot (100) as someData
Need to sort Ratspatoot using the value in Ratspatoot.biggernumber. This
one is probably very simple and I'm just missing something somehow.
Thanks in advance.