Setting focus to a control within a usercontrol

G

Guest

I have a user control that contains a grid. I want to set focus to the grid
when the user control receives focus.

I have tried calling grd.focus() for the gotfocus of the user control, but
that doesnt work.

Any ideas?

Thanks
 
W

WineNCheese

One easy way is to set the TabIndex of the grid to 0 (and any other controls
to subsequent #s).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top