i try to combine GUI with class - no success

Posted by Gold on Stack Overflow See other posts from Stack Overflow or by Gold
Published on 2010-04-06T16:23:29Z Indexed on 2010/04/06 20:23 UTC
Read the original article Hit count: 177

Filed under:
|

hi

i made a class that make registration to my WinCE program.

how i can from the class draw pannel + textbox, and catch the enter press

from the textbox ?

i try to do this:

   TextBox tb=new TextBox();
tb.Location=new Point(10,10);

Panel pn=new Panel();
pn.Dock=DockStyle.Fill;
pn.Controls.Add(tb);

this.Controls.Add(pn);



 but i got error in: this.Controls.Add(pn);

is there any simple sample code for this ?

thank's in advance

© Stack Overflow or respective owner

Related posts about c#

Related posts about windows-ce