Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to get user name from the operating system
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00717731
Message ID:
00718020
Views:
21
>Wow--I'd been looking for a while and right after I posted this msg I think I found it--SYS(0). If anyone knows of another better one please let me know.
>

As long as all you need is the Windows login ID, SYS(0) or the WSH Wscript.Network's UserName and UserDomain properties are fine; if you need to get the identity used to connect to a specific network resource, you'll need to use some API calls.

>JR
>
>>I have a client who's on W2K server. They want to create an audit trail in a program I wrote for them, which records user name. However, they don't want to have to have a log-in screen in the program I made (the network log-in is sufficient).
>>
>>How can I interrogate W2K to get the user name in VFP6?
>>
>>JR
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Reply
Map
View

Click here to load this message in the networking platform