Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Get the windows system Directory in Win 2K
Message
From
09/04/2002 03:27:31
 
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00642313
Message ID:
00642494
Views:
10
>getenv("windir") will return the path of windows (c:\winnt). You just have to add The "\system32" part ...

Don't use the environment variables - they can be changed. There are API calls that will retrieve the Windows, system and temporary directories, as well as methods to retrieve this information from the Special Folders collection of the Shell.Application object. All of the above are far more reliable than hitting the environment variable strings.

See the FAQ and Win32 API section of UT for details.
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
Next
Reply
Map
View

Click here to load this message in the networking platform