Bansaw
16th July 2010 13:41 UTC
Creating a .lnk that launches Windows Explorer with parameters ...?
I want to create a lnk in the start menu to launch windows explorer with parameters.
Here's what I am using:
CreateShortCut "$SMPROGRAMS\VMS Images\Open Images folder.lnk" "$WINDIR\explorer.exe /root,c:\VMS images"
Its not working, although it works fine from the Cmd prompt.
Does NSIS complier not like the forward slash or something else?
thanks,,
MSG
16th July 2010 14:12 UTC
VMS images contains a space, and therefore needs to be put between quotes.
Bansaw
16th July 2010 14:24 UTC
thanks
When I look at the .lnk it creates, its properties, I see that two characters are not coming out:
The colon : after C so C:\ becomes C\
the forward slash before root is also not coming out.
Bansaw
16th July 2010 17:00 UTC
I got it, - the parameters MUSt be in a separate string completely from the string.
So, this won't work:
CreateShortCut "$SMPROGRAMS\VMS Images\Open Images folder.lnk" "$WINDIR\explorer.exe /root,c:\VMS images"
But this will:
CreateShortCut "$SMPROGRAMS\VMS Images\Open Images folder.lnk" "$WINDIR\explorer.exe " "/root,c:\VMS images"