Click here to download the WindowsDir.dll file.
Questions and Answers
=====================
Q: How do I get the WindowsDir.dll to
return the Windows or Windows System directory name?
-------------------------------------------
A: You will need to "Reference" the WindowsDir.dll file from your module menu.
Use the Browse button to locate that file on your system.
NOTE: Sometimes, MS Access does not show DLL files when searching for files to reference.
So, once you locate the directory, simply type in the WindowsDir.dll filename.
After the "Reference" has been taken care of, all you do is call the function
behind your command button like the following:
Dim strRetVal As String
strRetVal = GetWinDir("WindowsDirectory") - OR -
strRetVal = GetWinDir("WindowsSystemDirectory")
That's it!
To access the "Reference" screen, you need to be within any module and select Tools, References
from the menu bar. Next, press the Browse button to locate the DLL. See screen shot examples below:
Q: What O/S does the WindowsDir.dll file run in?
-------------------------------------------
A: The WindowsDir.dll file runs on Win9x, Win2000, and NT platforms.
Known Problems & Application Notes
==================================
* No problems to report after testing on Win9x, Win2000, and NT platforms.
* No warranty express or implied, is given as to the use of this DLL (Dynamic Link Library).
We hope that you find the WindowsDir.dll utility very useful. Please tell others
about it.