owinterton Posted March 18, 2003 Posted March 18, 2003 Since my app is going to live on a Windows 2000 SQL Server, I am trying to use the windows username and password for my app. How do I go about using the log in or accessing the username and password for the current user? I have found VB6 code but it doesn't work in my app for .NET. Any suggestions? Quote
Cywizz Posted March 18, 2003 Posted March 18, 2003 Well, seeing that windows already took care of the authentication by checking your password, I suggest you leave the password and only use the username. You can get the user that created your app thread with the Environment.UserName property. Hope it helps... Quote Howzit??
*Experts* Nerseus Posted March 18, 2003 *Experts* Posted March 18, 2003 If you need the domain and username, use: System.Security.Principal.WindowsIdentity.GetCurrent().Name -Ner Quote "I want to stand as close to the edge as I can without going over. Out on the edge you see all the kinds of things you can't see from the center." - Kurt Vonnegut
ashrobo Posted April 7, 2003 Posted April 7, 2003 If you need the domain and username, use: System.Security.Principal.WindowsIdentity.GetCurrent().Name -Ner this is what i've been searching high and low for.. ;) Quote
Ellis Posted June 10, 2003 Posted June 10, 2003 Olaf, I posted this thread, and got a similar response... http://www.xtremedotnettalk.com/showthread.php?s=&threadid=72356 have you had any luck in confirming the windows password a second time?? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.