A
Andrew Banks
How wold I loop through a set of buttons on a web form and change some
properties?
I have some buttons named as follows
btn1User
btn2User
btn3User
btn4User
btn5User
I need to change a few of their properties in a loop and am having problems
referencing them with the value of the int used in the loop. For example (n
is the int used in the loop)
Idea 1
btn+n+User.Visible
Idea 2
string theButton = "btn"+n.ToString()+"User"
theButton.Visible
properties?
I have some buttons named as follows
btn1User
btn2User
btn3User
btn4User
btn5User
I need to change a few of their properties in a loop and am having problems
referencing them with the value of the int used in the loop. For example (n
is the int used in the loop)
Idea 1
btn+n+User.Visible
Idea 2
string theButton = "btn"+n.ToString()+"User"
theButton.Visible