Click here to Skip to main content
15,889,843 members
Home / Discussions / C#
   

C#

 
GeneralRe: Display data from text file to LISTVIEW Pin
ksanju10009-Jun-05 1:12
ksanju10009-Jun-05 1:12 
GeneralRe: Display data from text file to LISTVIEW Pin
ksanju10009-Jun-05 19:40
ksanju10009-Jun-05 19:40 
Generalresize the Button control Pin
prinz_simo8-Jun-05 0:26
prinz_simo8-Jun-05 0:26 
GeneralRe: resize the Button control Pin
MoustafaS8-Jun-05 2:21
MoustafaS8-Jun-05 2:21 
GeneralMS Word spell checker Pin
Gktony8-Jun-05 0:01
Gktony8-Jun-05 0:01 
GeneralRe: MS Word spell checker Pin
Anonymous9-Jun-05 4:03
Anonymous9-Jun-05 4:03 
Generalload a 256 color cursor Pin
Anonymous7-Jun-05 23:40
Anonymous7-Jun-05 23:40 
GeneralText box not accepting focus Pin
GazzaJ7-Jun-05 23:14
GazzaJ7-Jun-05 23:14 
Hi all,

I have a simple login form to my application which displays textboxes for username, password and server (tabindexes in the order given). The user name and server values get set from the last login if they have been saved to a config file. In the form load event I check to see if the user name has been populated and if so I would like the password box to have focus e.g.

private void frmLogin_Load(object sender, System.EventArgs e)
{
if (txtUserName.Text.Length > 0)
txtPassword.Focus();
}

This doesn't work however. If I capture the result of the Focus call it returns false. Am I missing something simple here? I don't want to go the route of programatically changing the tab order.
GeneralRe: Text box not accepting focus Pin
NormDroid8-Jun-05 0:10
professionalNormDroid8-Jun-05 0:10 
GeneralRe: Text box not accepting focus Pin
GazzaJ8-Jun-05 1:52
GazzaJ8-Jun-05 1:52 
GeneralLog in/Log out time from Active Directory Pin
Zapss7-Jun-05 22:38
Zapss7-Jun-05 22:38 
GeneralRe: Log in/Log out time from Active Directory Pin
Dave Kreskowiak8-Jun-05 6:56
mveDave Kreskowiak8-Jun-05 6:56 
GeneralRe: Log in/Log out time from Active Directory Pin
Zapss10-Jun-05 18:58
Zapss10-Jun-05 18:58 
GeneralCreating a self-executing file from within a C# application Pin
Anonymous7-Jun-05 22:34
Anonymous7-Jun-05 22:34 
GeneralRe: Creating a self-executing file from within a C# application Pin
Anonymous8-Jun-05 1:50
Anonymous8-Jun-05 1:50 
Questionuser's password from active directory ? Pin
Tee+7-Jun-05 22:31
Tee+7-Jun-05 22:31 
AnswerRe: user's password from active directory ? Pin
Carsten Zeumer7-Jun-05 22:36
Carsten Zeumer7-Jun-05 22:36 
AnswerRe: user's password from active directory ? Pin
Dave Kreskowiak8-Jun-05 6:52
mveDave Kreskowiak8-Jun-05 6:52 
Generalload multilevel png files Pin
Anonymous7-Jun-05 21:42
Anonymous7-Jun-05 21:42 
GeneralIO ports Pin
Niklas Ulvinge7-Jun-05 21:28
Niklas Ulvinge7-Jun-05 21:28 
GeneralRe: IO ports Pin
BrianCR898-Jun-05 7:23
BrianCR898-Jun-05 7:23 
GeneralRe: IO ports Pin
Niklas Ulvinge9-Jun-05 3:03
Niklas Ulvinge9-Jun-05 3:03 
GeneralRe: IO ports Pin
BrianCR899-Jun-05 6:27
BrianCR899-Jun-05 6:27 
GeneralRe: IO ports Pin
Niklas Ulvinge9-Jun-05 7:08
Niklas Ulvinge9-Jun-05 7:08 
GeneralAccess GDI+ Image pointer from unmanaged C++ dll... Pin
SpiderMan7-Jun-05 21:21
SpiderMan7-Jun-05 21:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.