Question Iterate over TabPages

Pretorian1971

New member
Joined
Jan 29, 2016
Messages
3
Programming Experience
Beginner
Hello everybody,

I'm new on this forum so don't know if I'm in the right topic.

I need to "do something" for 7 tabpages:

For Each c In Me.TabPage1.Controls
"do something"
Next
For Each c In Me.TabPage2.Controls
"do something"
Next
...


Was hoping to solve it like this:

For i as integer = 1 to 7
For Each c In Me.TabPage(i).Controls
"do something"
Next
Next

Unfortunately this would have been too easy. :) Can somebody point me in the right direction please ?

Grts,

Marc
 
Back
Top