The following folder constants may be used within Software Update Wizard scripts and expand to the corresponding folder on the user's computer at run time:
| Constant | Expands to... |
|---|---|
| <WINDIR> | The Windows folder of the client PC. |
| <SYSDIR> | The System folder of the client PC. |
| <USERNAME> | The name of the logged on user of the machine |
| <COMPUTERNAME> | The name of the user's computer, as returned by the API function GetComputerName(). |
| <TEMPDIR> | The user's temp folder (as returned by the GetTempPath() Windows API function). |
| <CLIENTFOLDER> | The folder containing the application which is hosting the Software Update Wizard wuw4.dll DLL. |
| <PROGRAMFILES> | The Program Files folder (equating to the registry key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\ ProgramFilesDir".) |
|
<DESKTOPFOLDER>
|
The current Windows desktop folder on the client PC.
|
|
<FONTFOLDER>
|
Virtual folder containing installed fonts. A typical path is C:\WINNT\Fonts. |
|
<STARTMENU>
|
File system directory containing Start menu items. A typical path is C:\Documents
and Settings\ username \Start Menu.
|
|
<STARTUP>
|
File system directory that corresponds to the user's Startup program group. The system starts these programs whenever any user logs onto Windows NT or starts Windows 95. A typical path is C:\Documents and Settings\ username \Start Menu\Programs\Startup. |
|
<MYDOCUMENTS>
|
The logged on user's 'My Documents' folder.
|
| <APPDATA> | The equivalent of "<username>/Application Data" |
|
<COMMONAPPDATA> |
The equivalent of "All Users/Application Data" |
|
|
The equivalent of "All Users/Documents" |
| <LOCALAPPDATA> | The equivalent of "<user name>/Local Settings/Application Data" (non-roaming) |
| Any SubmitVariable defined in script | Substitutes specified registry key contents for the SubmitVariable constant. |
The Software Update Wizard keywords which can take advantage of folder expansion are:
| Keyword | Expands to... |
|---|---|
| AdditionalFile= | Lets you specify an additional file to be downloaded and installed within a section. The file is additional to the principal file specified in the Filename or Zipfile keyword lines. |
| Bitmap | Change the default dialog bitmap image to one of your own |
| CheckFileExists | Update section will only be processed if file specified in this keyword exists on user's PC. The inverse behaviour is possible using the optional "<NOT>" syntax. |
| DelTree | Deletes the specified folder tree. |
| ExecAfter | Launch a process (e.g. a program) after the update file has been downloaded |
| ExecBefore | Launch a process (e.g. a program) before the update file is downloaded |
| FileDate | Checks the file specified in the Filename= or Zipfile= keyword and only processes the update if the version on the user's computer is older than the date specified in the 'FileDate' line |
| FileVersion | Checks the file specified in the Filename= keyword and only processes the update if the version on the user's computer is earlier than the version specified in the 'FileVersion' line |
| Icon | Change icon displayed on the Software Update Wizard dialog title area from its default icon |
| MoveFileEx | In conjunction with Reboot, facilitates the update of in-use files. (N.b. The recommended method for replacing in-use files is using WindowTitle or KillProcess. Use MoveFileEx in situations where WindowTitle or KillProcess are inappropriate.) |
| TargetFolder | Specify the target folder for the update file |
| XML_FileVersion= | Used in 2-pass update scripts to add the version number of a specified file to the generated XML file. |