A new Flexera Community experience is coming on November 18th, click here for more information.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

modifying shortcut information based on user input

Hello all 🙂

This is my first time trying to create a installation project with installshield.

My question is, how would I go about programatically modifying a shortcut with user supplied values? The shortcut needs to contain the path to the installation directory.

The shortcut right now looks like:
"c:\progra~1\....\program.exe -datadir h:\profile"

I need to be able to change the h:\profile to whatever directory the user installs into. By default, its h:\profile. But what if its something different? Then the link won't work.

Thanks!
(1) Reply
The input control that you used for the user to type into would have been bound to a property lets say in this case your property was called DATADIR. You then write the shortcut arguments as -datadir "[DATADIR]".

Word of warning though your user may enter a path with or without a trailing slash such as h:\profile or h:\profile\. If your app cannot handle this then you will need to create a custom action to manipluate the property value to accomodate this as well.