Dynamic creation of control names .. is it possible?
Greetings everyone,
Is it possible to use variables in order to construct the name of a control?
I am not trying to create the controls dynamically, what I am looking for is a way of referring to a control's name by using a variable.
Example:
Say these controls exist already: control1, control2, and control3
What I would like to do is somehow be able to make a statement such as:
var = 1;
"control"+ var.Text = "whatever";
I know the syntax above is incorrect, but it is to illustarte my question.
Thanks for the input.
4 Answers
Know the answer? Post it. Somebody with the same question will find it here.

KlytusLord12 pointsPosted May 20, 2005, 10:53 AM EDT
Andrew Wooster77 pointsPosted May 24, 2005, 4:48 AM EDT
spgilmoreRank #1,616 · 964 pointsPosted May 24, 2005, 9:14 AM EDT
spgilmoreRank #1,616 · 964 pointsPosted May 24, 2005, 9:34 AM EDT