How can I add a file to an InstallShield component specifying a relative path to the InstallShield project in order to make it easy compiling the project on different machines?
With the free VS Limited Edition of InstallShield, setting custom paths doesn't look possible. So hacking the ISL file may be necessary having only a few predefined path options available.
Here are the predefined path variables I found in the 2013 Express docs: (Verify in case of typos)
Predefined Path Variable Value InstallScript Path Variable
--------------------------------------------------------------------------------------------------------------
<ProgramFilesFolder> C:\Program Files\ <PROGRAMFILES>
<CommonFilesFolder> C:\Program Files\Common Files\ <COMMONFILES>
<WindowsFolder> C:\Windows\ <WINDIR>
<SystemFolder> C:\Windows\System32\ <WINSYSDIR>
<ISProjectFolder> C:\InstallShield 2013 Projects\
<ISProjectDataFolder> <ISProjectFolder>\ProjectName <ISPROJECTDIR>
<ISProductFolder> C:\Program Files\InstallShield\2013
<ISRedistPlatformDependentFolder> C:\Program Files\InstallShield\2013\
.\Redist\Language Independent\i386
<ISRedistPlatformDependentExpressFolder> C:\Program Files\InstallShield\2013\
.\Redist\Language Independent\
.\i386 Express
My VS solution includes both an Outlook AddIn and an InstallShield LE setup project. Although InstallShield was including the AddIn generated output and related assemblies, neither the manifest nor vsto files were included. So I needed to specify these separately. This worked for one workstation; however, another workstation sharing the solution had a different source directory structure giving unresolved sources.
The manifest and vsto files were added by InstallShield with absolute paths. A symlink common to all the workstations could have solved the issue, but I decided to hack the ISL files to see if it's possible to use relative paths realizing the ISL file might require maintenance hacking in the future.
In order to get the common parent directory (i.e., the solution directory in my case,) I specified the following two parent selectors (..\..) in the ISL for special artifacts listed in <table name="File">.
...<td><ISPROJECTDIR>..\..\MyProject\bin\Release\...
where HTML entities are used for the surrounding less-than/greater-than symbols of the <ISPROJECTDIR> variable.
I ran a second test (which should have been the first) using the <ISPROJECTFOLDER> variable instead of <ISPROJECTDIR>. In this test, only one parent selector was necessary:
...<td><ISPROJECTFOLDER>..\MyProject\bin\Release\...
So far things seem to be resolving correctly but your relativity may vary.