Shortcuts being created in C:\Users\Public\Desktop\

Got a problem you cannot solve? Try here.
Post Reply
AlexApostolou
Posts: 3
Joined: Thu Aug 12, 2010 4:52 am

Shortcuts being created in C:\Users\Public\Desktop\

Post by AlexApostolou »

In my installer, I am creating shortcuts, for the main application executable and the uninstaller, in the top level folder of the installation.

When this folder is on the desktop, the application is going into "C:\Users\USERNAME\Desktop\ApplicationName" while the shortcuts are having a second directory, of the same name, being created in "C:\Users\Public\Desktop\ApplicationName".

Therefore, I have two folders on the desktop called ApplicationName and the public one only contains the shortcuts, and the other, all the application files/folders.

The shortcuts are being created in the same $TARGETDIR$ variable as all the other files/folders, and no matter where I move the create shortcut statements too, they always end up in this split. I have tried both advertised and regular and the outcome is identical.

Please, any help would be very much appreciated,
Alex
mills
Posts: 814
Joined: Tue Jul 06, 2010 7:10 pm
Location: Honolulu, HI

Re: Shortcuts being created in C:\Users\Public\Desktop\

Post by mills »

This happens when the option to install this application for all users is selected.

So, there is some sensibility in this.

If you log on as another user, only the folder with the shortcut appears.

You should be able to work around this by adjusting the code:

if Variable ALLUSERS Equals TRUE
Set Variable SHORTCUTFOLDER to $SHORTCUTFILESALL$\$STARTMENU$
else
Set Variable SHORTCUTFOLDER to $SHORTCUTFILES$\$STARTMENU$
end
Andy Mills
InstallAware
Other Help:
White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help - Press F1 in the InstallAware IDE.
AlexApostolou
Posts: 3
Joined: Thu Aug 12, 2010 4:52 am

Re: Shortcuts being created in C:\Users\Public\Desktop\

Post by AlexApostolou »

Hi, thanks for the reply.

I don't quite understand why, if the Create Shortcut properties has a "Link Location" attribute, and if I set that to $TARGETDIR$, then why wouldn't I expect that the shortcut would be created in the $TARGETDIR$ ?

Be that as it may, as this installer is specifically designed for a single user, I took your advice, modified it because there is no ALLUSERS and specified this:

Code: Select all

 Set Variable SHORTCUTFOLDER to $TARGETDIR$
hoping to avoid the complication of where else it might be put, but this has had no effect.

What else can you advise?

Thanks
Alex
AlexApostolou
Posts: 3
Joined: Thu Aug 12, 2010 4:52 am

Re: Shortcuts being created in C:\Users\Public\Desktop\

Post by AlexApostolou »

Ah, I got, I had also to set ALLUSERS to FALSE, and that did the trick.
mills
Posts: 814
Joined: Tue Jul 06, 2010 7:10 pm
Location: Honolulu, HI

Re: Shortcuts being created in C:\Users\Public\Desktop\

Post by mills »

Whew! You had me worried for a bit!
8)
Andy Mills
InstallAware
Other Help:
White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help - Press F1 in the InstallAware IDE.
Post Reply