Subject: Question on FOCUS?
Posted By: savoym Post Date: 2/13/2004 11:22:34 AM
When loading a windows form (NOT A WEB FORM), how do I define the form control that I need to have the default FOCUS when the form is loaded?

This is what I have tried but it does not work:

private void frmInvoiceMgmt_Load(object sender, System.EventArgs e)
    {
        //txtClientID.Focus();
        frmInvoiceMgmt.ActiveControl = this.txtClientID;
    }

Any help would be appreciated.  Thanks.
Reply By: agarwalmk Reply Date: 2/13/2004 11:32:47 AM
You can set tabindex property of the control to 0.

Reply By: savoym Reply Date: 2/13/2004 11:39:16 AM
I'm new to C# and slooooooowly trying to learn.  Thanks much for the help and your time.
Reply By: ldcn Reply Date: 2/15/2004 7:15:24 AM
ÎÒÏëÒªÕÒµ½<<Beginning Visual C#>>Õâ±¾ÊéµÄÁ·Ï°ÌâµÄ´ð°¸,Çë°ïæ,лл!


Go to topic 9810

Return to index page 948
Return to index page 947
Return to index page 946
Return to index page 945
Return to index page 944
Return to index page 943
Return to index page 942
Return to index page 941
Return to index page 940
Return to index page 939