471,318 Members | 3,236 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,318 software developers and data experts.

Windows Form login question

Hi,

In my C# Windows Form project, saying in form frmLogin I have two TextBoxes,
UserName, Password.
How do I make the frmLogin remember the current UserName,
so next time I login to the frmLogin, the UserName textbox has the last time
login UserName value?
given that the application is running on Windows XP system.
Thanks for help.
Jason
Feb 19 '06 #1
4 5235
you could store the value in the registry maybe.

msdn.microsoft.com/library/en-us/dndotnet/html/persistappsettnet.asp

are you having seperate userids for your program ?

or using the Currently Logged In User ?

Feb 19 '06 #2
Thanks!
If the User is the first time enter into the application, the user has to
key in the UserName and Password to login.
After that, the UserName textbox in frmLogin will bring out the last
UserName value logged in.
<fa*********@gmail.com>
???????:11*********************@g14g2000cwa.google groups.com...
you could store the value in the registry maybe.

msdn.microsoft.com/library/en-us/dndotnet/html/persistappsettnet.asp

are you having seperate userids for your program ?

or using the Currently Logged In User ?

Feb 19 '06 #3
On Sun, 19 Feb 2006 16:28:51 +0800, "Jason Huang"
<Ja************@hotmail.com> wrote:
Thanks!
If the User is the first time enter into the application, the user has to
key in the UserName and Password to login.
After that, the UserName textbox in frmLogin will bring out the last
UserName value logged in.
<fa*********@gmail.com>
???????:11*********************@g14g2000cwa.googl egroups.com...
you could store the value in the registry maybe.

msdn.microsoft.com/library/en-us/dndotnet/html/persistappsettnet.asp

are you having seperate userids for your program ?

or using the Currently Logged In User ?

Is this application on the users's machine or a server?

Storing the last user will work if the app is on a user machine, but
if it's on a server being accessed by multiple users you'll always get
the last user who logged in, but it may not be the current user.

Does that make sense?

Otis Mukinfus
http://www.otismukinfus.com
http://www.tomchilders.com
Feb 19 '06 #4
Mel
Download the example TaskVision from Microsoft, includes source code. It
has a login form that does exactly what you want.


"Jason Huang" <Ja************@hotmail.com> wrote in message
news:uL****************@TK2MSFTNGP09.phx.gbl...
Hi,

In my C# Windows Form project, saying in form frmLogin I have two
TextBoxes,
UserName, Password.
How do I make the frmLogin remember the current UserName,
so next time I login to the frmLogin, the UserName textbox has the last
time login UserName value?
given that the application is running on Windows XP system.
Thanks for help.
Jason

Feb 20 '06 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Babu Mannaravalappil | last post: by
4 posts views Thread by Cantekin Guneser | last post: by
7 posts views Thread by programming | last post: by
30 posts views Thread by diane | last post: by
1 post views Thread by Michael Howes | last post: by
3 posts views Thread by stacey | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.