09.12.2012 Views

InstallShield 2012 Express Edition User Guide - Knowledge Base ...

InstallShield 2012 Express Edition User Guide - Knowledge Base ...

InstallShield 2012 Express Edition User Guide - Knowledge Base ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 7: Specifying Installation Information<br />

Configuring General Project Settings<br />

As an alternative, you can manually enter the path in the INSTALLDIR setting.<br />

Note: Selecting a new folder property in the Set INSTALLDIR dialog box overwrites the contents of the value in the<br />

INSTALLDIR setting. You can specify a subfolder of any folder property by separating subfolders with a backslash—for<br />

example, [ProgramFilesFolder]My Company\Program.<br />

When specifying a destination folder, you cannot include a space after the closing square bracket (]), or before or after a<br />

backslash (\). For example, the following paths are not valid:<br />

[ProgramFilesFolder] \YourCompany\default<br />

[ProgramFilesFolder]YourCompany\ default<br />

When you use an installer folder property such as INSTALLDIR, you are specifying a default value. An<br />

end user could change this value by setting a property when launching Msiexec.exe at the command line<br />

or by selecting a new destination folder for a feature in the Custom Setup dialog.<br />

INSTALLDIR and the Registry<br />

You can set the default installation directory for your installation to be a key value found in the target<br />

system’s registry. This directory is stored in the INSTALLDIR property in the General Information<br />

view.<br />

One limitation of using a registry entry to set the value of INSTALLDIR is the fact that the registry<br />

entry must exist on the target system before your installation starts. If the registry entry cannot be<br />

found, INSTALLDIR is set to the last valid value you had entered for it.<br />

For example, when you first create an installation project, the value of INSTALLDIR is<br />

[ProgramFilesFolder]Your Company Name\Default. If you were to change this to read from the registry,<br />

and the registry entry is not found, INSTALLDIR reverts to the previous value of<br />

[ProgramFilesFolder]Your Company Name\Default.<br />

Setting INSTALLDIR from the Registry<br />

Task To set the INSTALLDIR value from the registry:<br />

1. In the View List under Organize Your Setup, click General Information.<br />

2. In the INSTALLDIR setting, enter the full path to the registry key containing the value you want to<br />

use. For example:<br />

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\Current Version\AppPaths\App.exe\<br />

Setting this value to<br />

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\Current\Version\AppPaths\App.exe will instruct<br />

<strong>InstallShield</strong> to get this value from a string named App.exe in the AppPaths key. Setting this value to<br />

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\Current\Version\AppPaths\App.exe\ (with trailing<br />

backslash) will instruct <strong>InstallShield</strong> to get this value from the default value of the key named App.exe.<br />

140 ISE-1800-UG01 <strong>InstallShield</strong> <strong>2012</strong> <strong>Express</strong> <strong>Edition</strong> <strong>User</strong> <strong>Guide</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!