Hi,
I have Login form, first time when open this form the cursor come in to UserID textbox and I have one setting button when I click this setting button another setting form is opened(I dont want to close Login form), after setting form closed the cursor did not come in to UserID textbox,
So how to set cursor in to UserID textbox after closing the setting form....
Loading
jayaramPosted Sep 15, 2011, 11:58 PM
Priya LingePosted Sep 15, 2011, 8:42 AM
I have two form,
On firstForm i have UserID textbox and 1 button as per ur requirment,
on click event of this button i open second form
after second form closed the cursor will go the userid textbox as below,
Form1.cs :
private void button1_Click(object sender, EventArgs e)
{
Form2 fr = new Form2();
fr.Show();
fr.FormClosed += new FormClosedEventHandler(fr_FormClosed);
}
void fr_FormClosed(object sender, FormClosedEventArgs e)
{
txtfirst.Focus();
}
Hope this will help you.
Thanks.