valiot
Posts: 80
Joined: Tue Dec 04, 2012 1:41 am

Conditional adding shortcuts via command line

By default my desktop shortcuts are set to be created. If i run the installer in /quiet mode then the shortcuts get installed as well. Is it possible to run in /quiet mode and do not install desktop shortcuts? How can i do this?
Eusebiu
Posts: 4959
Joined: Wed Nov 14, 2012 2:04 pm

Re: Conditional adding shortcuts via command line

Hi

In order to achieve this you can create a property in the Install Parameters page (i.e. DESKTOP) and set its value to 1.

Then go in the Organization page, select the component that contains your shortcut and set its condition based on the property you created (DESKTOP = 1).

When you run your package in command line you can change the DESKTOP property value (i.e. DESKTOP=0). In this case the shortcut will not be installed anymore.

The Create Shortcut based on checkbox status thread shows you how to move a shortcut in its own component.

Let us know if this helps, otherwise give us more details about your scenario.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
valiot
Posts: 80
Joined: Tue Dec 04, 2012 1:41 am

Re: Conditional adding shortcuts via command line

Thanks for this. I tried your suggestion but it has one issue. I have two shortcuts with my main exe as the target. One shortcut is the desktop. The other is the start menu. Both of those shortcuts are in the same component. So how can I condition the desktop shortcut but NOT the start menu shortcut?
valiot
Posts: 80
Joined: Tue Dec 04, 2012 1:41 am

Re: Conditional adding shortcuts via command line

I think I figured it out by reading the thread you mentioned: http://www.advancedinstaller.com/forums ... =5&t=20972
Eusebiu
Posts: 4959
Joined: Wed Nov 14, 2012 2:04 pm

Re: Conditional adding shortcuts via command line

You're welcome. Glad it worked.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”