How do I get the Windows account name (common name) using Windows Authentication?

mday2792

Member
Joined
Jan 16, 2007
Messages
5
Programming Experience
3-5
Anyone know how to get the name on the windows account (Other than using LDAP) using windows authentication such as "Joe Smith"? I believe this is also referred to as the common name.
 
That will only give me my username. I need the name on the account like what you see at the top when you click the windows xp start button.
 
You are correct. Searching the Registry came to mind. I found myself in:

HKEY_CURRENT_USER\Software\Microsoft\User Location Service\Client

however, I cannot guarantee that is always the case. Not sure if you can do it without going to LDAP/Active Dir.
 
Back
Top