|
-
Nov 18th, 2002, 04:02 AM
#1
Thread Starter
Addicted Member
How do I get the full username?
Hi
In Microsoft Word if you go into the View\Options dialog and blank the text boxes in the User Information tab, the next time Word will start up, it'll display a dialog box prompting you to put in your name and initials. The Name text box is defaulted to my full name, not my network logon name.
e.g.
My Network username is MarkJon
but the name text box is defaulted to Mark Jones, which is my full name
I know how to use the GetUserName API to get the Network username (e.g. MarkJon), but how do I get the full name (e.g. Mark Jones).
Thanks in advance
Last edited by VB6Coder; Nov 18th, 2002 at 04:31 AM.
-
Nov 18th, 2002, 04:59 AM
#2
Banned
I think it is stored in the registry somewhere. Perhaps you can find the registry entry if you search your registry on your name.
-
Nov 18th, 2002, 05:12 AM
#3
Thread Starter
Addicted Member
I've done a search in the registry and my name is all over the place, mainly under install keys.
Nothing seems to stand out saying this is where I can get the full username.
-
Nov 18th, 2002, 05:43 AM
#4
If you are using Win NT or later, you can use the NetUserGetInfo API call. Search the forum for an example.
-
Nov 18th, 2002, 05:47 AM
#5
PowerPoster
See this link. I think this is where you get the full username.
-
Nov 18th, 2002, 06:26 AM
#6
Thread Starter
Addicted Member
Thanks guys. You were all correct.
I did a search on NetUserGetInfo and I found this thread which told me where to find the full user information in the registry.
It is stored in:
HKEY_CURRENT_USER\Software\Microsoft\MS Setup (ACME)\User Info\DefName
I tried using the NetUserGetInfo API but it didn't work. Probably because we've got a mixture of NT and NetWare servers here.
Thanks for all your help
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|