Indeed, you are right. That might not work for paths such as the one you mentioned.
However, in this case, the path variables may come in handy. Path variables
are used to specify locations on the file system.
For better understanding, let's work with an example.
On a VM, I have created an Advanced Installer project, containing only one .txt file in the "Files and Folders"
page ("Application Folder"
). This file is linked from the following location:
Let's say that we want to create a path variable for this file. In order to create a path variable, you can go to "File" --> "Settings" --> "Path Variable"
In the "Edit Path Variables"
dialog, press on the "New..."
button. The path variable I have created is the following:
Now we have to convert the paths from our project in order to support path variables. To do so, click on the "Wizards"
tab from the toolbar and then click on the "Convert Paths"
After doing so, a Wizard will be spawned, allowing you to convert existing project paths to use path variables.
"Next" --> "Files" --> here Advanced Installer automatically detects which files use the path variable --> "Next" --> "Next" --> "Finish"
Save the project (ctrl+s).
Now, upon moving the project from the VM to my machine, here is how the path to the .txt file looks like:
As you can notice, the project does not recognize the path variable. This means that we need to create it. Now, of course, this all depends on where the file (in our case, the .txt file) is on my machine. For instance, I have moved the .txt file to:
Now, in order to create the path variable for the new machine, all we have to do is to go to "File" --> "Settings" --> "Path Variables"
. There, we should create the new path variable for our machine (it should have the same name as the one created earlier. As you can see, it is referenced by name. However, the path does not have to be the same). Here is how the path variable could look in our case:
Value: "Select" --> "Folder on disk..." --> now we should select our folder (D:\zzz)
Now, if you go to "Files and Folders"
page, the files will automatically be referenced to your path.
Hope this helps.