Brahnsuk
Posts: 38
Joined: Thu Feb 10, 2011 6:06 pm

How to use variables in Pre-Build Events

Fri Dec 04, 2015 10:24 am

Hi,

I already have read about that it is not possible to change images for the prerequisite dialogs from the GUI. So I created a pre-build event for that and copy/replace for each build the pictures with the original under "C:\Program Files (x86)\Caphyon\Advanced Installer 12.5.1\themes\graphite\resources\variations\blue-cave", all fine!
But every time I install a new version of AI, the path is different (because of the version number). My idea was to use variables in the arguments of the pre-build events.
"[|AI_AIP_FOLDER]" works just fine, so I searched for another variable for the program-folder of AI. I found the "AI_THEMES" path-variable in "Options|Path Variables", so how can I use this variable in an argument?
I've also tried to create a project-property with that variable as value, but unfortunately the variable/value will not be resolved.
Current Version of AI: 16.5

Daniel
Posts: 8237
Joined: Mon Apr 02, 2012 1:11 pm
Contact:  Website

Re: How to use variables in Pre-Build Events

Fri Dec 04, 2015 12:45 pm

Hello,

I'm afraid we don't have support to use path variables in the build event dialog field. Maybe we can add such an improvement in a future version of Advanced Installer. Thank you for your suggestion.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Ruben
Posts: 57
Joined: Fri Apr 10, 2015 2:35 pm

Re: How to use variables in Pre-Build Events

Mon Dec 28, 2015 4:53 pm

I'd like to vote for that.
Currently, we need to run pre-build scripts manually outside the installer.

Our scenario is:
We pack client side upgrades (as zip file) into our server application.
Our zip must be named to contain the product version as part of the filename.

We would use a Pre Build Event to put the [ProductVersion] into the zip file name.

All The Best,
Ruben

Daniel
Posts: 8237
Joined: Mon Apr 02, 2012 1:11 pm
Contact:  Website

Re: How to use variables in Pre-Build Events

Tue Dec 29, 2015 10:17 am

Hello Ruben,

I'm not sure I fully understood your pre-build requirements. Please note that we do have support to use property pseudo-formatted references (i.e. [|ProductVersion]) in our pre-build event dialog.

Let us know if this helped, otherwise please give us more details about your pre-build event requirements.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”