Archive: Shortcut in Vista


Shortcut in Vista
This error occurs in Windows Vista SP1 when i try to create the shortcut on the desktop. The desktop is not the default one but changed to "D:\desktop" using Tweak UI power tool given by windows to change the registry values which changes the default desktop folder.

CreateShortCut "$DESKTOP\Project1.lnk" "$INSTDIR\Project1.exe"

When i execute the above command the shorcut is created in the desktop folder inside "C:\user\desktop" not "D:\desktop". The NSIS version i am using is 2.45. Can anyone help me out?


http://sourceforge.net/tracker/?func...49&atid=373085

Not the first time this is reported, but NSIS uses the documented way to get the path, so you either changed it using the wrong registry key or you are hitting a windows bug


Actually i am using the default variable of desktop with SetShellVarContext also default(Current). The variable $DESKTOP has the value "D:\desktop" but when CreateShortCut command executes the shortcut is created inside "C:\user\desktop". This happens only in Vista. In XP it works fine.