Click here to Skip to main content
16,017,852 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
Hello...
Textbox is not getting focused when placed on tabpageview control...

But when i place on form directly then its focussing...

Its bit crucial to me...

Can u suggest me what might be the issue...
Posted

In addition to what Toli says, check this: the TextBox.CanFocus property must be true.

—SA
 
Share this answer
 
Set the TabOrder property to Zero for both the TabControl / TabPage and the TextBox.
Or, call TextBox.Focus() in the Form's Shown event.
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 23-Mar-11 17:32pm    
Correct, my 5, but it looks something else is wrong.
--SA
Sergey Alexandrovich Kryukov 23-Mar-11 17:33pm    
...yes, one more thing: CanFocus. Please see my Answer.
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900