|
-
September 20th, 2002, 10:29 AM
#1
Set Focus in form_Load
I am trying to set the focus to textBox3 in the form_Load method - but the form's tab order says set the focus to textBox1. I do not want to change the tab order as this is a condtional move - Activate is not an option.
In VC++ there was an option to return TRUE/FALSE from OnInitDialog for just this purpose.
Any ideas?
Thanks
Ian
private void form_load(object sender, System.EventArgs e)
{
// textBox1 text entered by reading a file (if exists)
if (textBox1.Text != "")
{
textBox3.Focus();
}
}
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|