Peter350
Posts: 30
Joined: Sat Oct 17, 2009 1:56 pm

Cannot move Shortcut to new feature/Component?

The Shortcuts Dialog seems to be buggy. The lower two checkboxes cannot be hidden (when set not visible, one of them remains visible) and, is only effective for Desktop shortcuts, the Start Menu shortcuts are created regardless. I have therefore decided to implement my own switches to control the installation of shortcuts.

I have created checkboxes on the VerifyReadyDlg, which set properties.

In Organization I then need a feature for the shortcuts, which I have created with a condition to test the property set by the checkbox.

A component is also needed within the feature, but needs a main Key resource which cannot be a shortcut, so i create a dummy registry value. I now have a component to host the conditional shortcut.

The problem is, when I create a shortcut, it automatically resides in the same Component as the file it targets, and cannot be moved. The shortcut is created with the default settings, is not a Key resource, and is not advertised.

Right-clicking the shortcut only gives me the menu items "Go to resource" "Add to list" and "Add children to list".

How can I move this shortcut away from the component where the target is installed, and into a new component?
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: Cannot move Shortcut to new feature/Component?

Hello,
The Shortcuts Dialog seems to be buggy. The lower two checkboxes cannot be hidden (when set not visible, one of them remains visible) and, is only effective for Desktop shortcuts, the Start Menu shortcuts are created regardless. I have therefore decided to implement my own switches to control the installation of shortcuts.
Please note that the ShortcutsDlg is a predefined dialog and has its own functionality tab called "Shortcuts Actions". If you need to hide or provide a default action for any of the shortcuts please do so from this tab. Any modifications you bring from the properties pane will alter the predefined functionality.
How can I move this shortcut away from the component where the target is installed, and into a new component?
The shortcuts to an installed file will be added to the component of their target. Since these shortcuts cannot be moved to another component, the solution is to use shortcuts to an external file. This type of shortcuts can be moved to any component, therefore each shortcut can be placed into a different feature.

Regards,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Peter350
Posts: 30
Joined: Sat Oct 17, 2009 1:56 pm

Re: Cannot move Shortcut to new feature/Component?

Hi mihai,

we still have both problems. Even if I use a new ShortCutsDlg with its default settings, then switch off the checkboxes, Desktop shortcuts are prevented from installing but not Start Menu shortcuts. We are on Win7 using AI 8.0.2

Our start menu shortcuts are standard shortcuts to installed files, not advertised, and their properties contain Paths like this:

Shortcut Target: APPDIR\MyExe.exe
Shortcut Folder: ProgramMenuFolder\test
Working Directory: APPDIR

I have tried creating the shortcuts as shortcuts to External Files, and then entering the Shortcut Target the same: APPDIR\MyExe.exe

This results in those shortcuts being created under random Components that have nothing to do with them, not as key resources, and still, I am unable to drag them to any other component, and when right-clicking on them the option "Move to new component" is grayed out.

So currently this is really quite frustrating because we seem to have no possible way to control shortcuts during installation which is a major drawback. Please let us know if these are confirmed issues and is there any workaround?

many thanks
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: Cannot move Shortcut to new feature/Component?

Hello,

I cannot reproduce this behavior on my test machine. Can you please send us the .AIP (project) and a verbose log of the installation to support at advancedinstaller dot com so we can investigate them?
I have tried creating the shortcuts as shortcuts to External Files, and then entering the Shortcut Target the same: APPDIR\MyExe.exe
Also, please note that the Shortcut Target text field is formatted and the correct syntax for the application folder property is :

Code: Select all

[APPDIR]MyExe.exe
Regards,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”