How to get the handle of a control after adding it programmingly

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi, Guys
After adding a control into a container programmingly, for example, myForm.controls.add(myControl), how can I reference this control in my code

Thank
william
 
Just use "myControl". This is a reference to the control itself. If you have
created this control inside a method then you can move the declaration for
the control to have member scope inside the form class. This would allow you
to access the control just like any other. Or have I missed something?

--
Tim Wilson
..Net Compact Framework MVP
{cf147fdf-893d-4a88-b258-22f68a3dbc6a}
william said:
Hi, Guys,
After adding a control into a container programmingly, for example,
myForm.controls.add(myControl), how can I reference this control in my code?
 
Back
Top