![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | How to update value of SystemInformation.UserName in Vista When I loaded Vista it appears that I entered my FirstName/LastName in one of the setup parameters. So, when I launch an application that I have written and get the value in SystemInformation.UserName, the value returned is "SLINDEED\Dean Slindee". What I want to be returned is "SLINDEED\dslindee". "dslindee" is the value that shows on the startup screen, and is also the administrator account. How can I change "Dean Slindee" to "dslindee"? Thanks, Dean S |
My System Specs![]() |
| | #2 (permalink) |
| | Re: How to update value of SystemInformation.UserName in Vista "Dean Slindee" <slindee@xxxxxx> wrote ... Quote: > When I loaded Vista it appears that I entered my FirstName/LastName in one > of the setup parameters. So, when I launch an application that I have > written and get the value in SystemInformation.UserName, the value > returned is "SLINDEED\Dean Slindee". What I want to be returned is > "SLINDEED\dslindee". "dslindee" is the value that shows on the startup > screen, and is also the administrator account. How can I change "Dean > Slindee" to "dslindee"? Hi Dean, It sounds like you have the Account Name and the Full Name back-to-front. In a normal scenario, user Fred Smith will have Account Name "fsmith" and Full Name "Fred Smith". When Fred Smith calls SystemInformation.UserName, it would return "fsmith" - the Account Name (not the Full Name). In your case, it sounds like you have account name "Dean Slindee" and Full Name "dslindee". Local accounts are a bit weird, coz you don't have the full ADSI/LDAP apparatus. But I think you can change this pretty easily in Administrative Tools, Computer Management. In the Computer Management snap-in, go to Local Users and Groups, Users, and locate "Dean Slindee" in the Name column. You'll probably see in the Full Name column "dslindee". Right click the account record and choose "Rename". Change "Dean Slindee" to "dslindee". Optionally, you might choose to change the Full Name "dslindee" to "Dean Slindee" ... but that has no effect on the value returned by SystemInformation.UserName. SystemInformation.UserName generally returns just the user's name (ie account name), not the full LanMan-style DOMAIN\user formatted name. For that, you may need to get the SystemInformation.UserDomainName property, then catenate the string with a "\" in the middle. Hope it helps, -- Andrew McLaren amclar (at) optusnet dot com dot au |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| Vista login "incorrect username or password" with correct username and password entry | Vista General | |||
| vista username on start menu | Vista General | |||
| Vista keeps asking me for Username/Password | Browsers & Mail | |||
| Vista, Username | Vista General | |||
| Vista Upgrade - don't know password or username | Vista account administration | |||