Windir Environment Variable Lost if Batch File Run from *.PIF
Article ID: 148948
Article Last Modified on 11/1/2006
APPLIES TO
- Microsoft Windows NT Workstation 3.5
- Microsoft Windows NT Workstation 3.51
- Microsoft Windows NT Server 3.5
- Microsoft Windows NT Server 3.51
This article was previously published under Q148948
SYMPTOMS
When you run a batch file from a *.PIF file on a Windows NT computer, the
environment variable "Windir" is not retained in the environment. Some
applications make use of this variable, and it is normally available
in the Windows NT environment. If it is not available, the application
may fail.
RESOLUTION
At the beginning of the batch file, place an entry that reads:
This restores the variable to the environment.
Additional query words: prodnt
Keywords: KB148948