I have a structure as follows
Structure Players
Dim Player1 as String
Dim Player2 as String
....... and so on
End Structure
If I now define a new object using this structure, is there a way to query through each of its children eg,
Dim Team as New Players()
Dim i as Integer = 1
Some code to find Team.Players1 since i = 1 but if i = 2, then use Team.Players2.
Then I can jump to a function specific to what player is current.
Team.Player?? (the one that matches to i) then do something else.
The way I am thinking about this is the same way you would loop through all of the controls on a form and look for a match in the controls name or text.
I know I could do it with a Select Case or If statements, but I am trying to do it without having to code a few hundreds lines.
Thanks
Steve
Structure Players
Dim Player1 as String
Dim Player2 as String
....... and so on
End Structure
If I now define a new object using this structure, is there a way to query through each of its children eg,
Dim Team as New Players()
Dim i as Integer = 1
Some code to find Team.Players1 since i = 1 but if i = 2, then use Team.Players2.
Then I can jump to a function specific to what player is current.
Team.Player?? (the one that matches to i) then do something else.
The way I am thinking about this is the same way you would loop through all of the controls on a form and look for a match in the controls name or text.
I know I could do it with a Select Case or If statements, but I am trying to do it without having to code a few hundreds lines.
Thanks
Steve