Run Time Controls

  • Thread starter Thread starter Gomathi
  • Start date Start date
G

Gomathi

hi,
I'm adding 5 Text box controls during runtime in my windows application. I'm
adding those in a for loop.
But i got only one text box as result in my form.
Why like this? And what i have to do for displaying all 5 text boxes?

Regards,
Gomathi
 
The reason might be you did not set size and position for each of them,
so the 4 have same size and position and that made you think that there
was only one.

Note that the controls you add at design time is just as "run time" as
the 5 text boxes above. The designer generate code for the controls in
InitializeComponents method and call this method in the form's
constructor - you might want to take a look at that method to see how
it set location/size of controls.

Thi
 
Back
Top