Showing results for 
Show  only  | Search instead for 
Did you mean: 

creating shortcut to non-existing network file


I need to create a shortcut to exe file in network location. I have no access there, I'm not even in this network. So I googled, and found this: - a great step by step guide.

So what I did is I run InstallShield, choose new project, new basic MSI.

Did all step by step, not adding anything else. Built MSI.

And on Windows 7 during installation I get error 1606 "could not access network location".

Only thing that did not work 100% during editing ISM was, that in step 2 I couldn't set [MYDIR] from drop list, so I had to type it by hand.

Any idea what went wrong? Did I miss something "obvious"? Or maybe some other tips, how to handle this one? It seems to be really easy, but I have no more ideas.
(3) Replies
check the logfile, should give you a clue..
Hello lucask.

There are three possible way to create package with shortcut to source in net location.
1) Create property with value which consist path to source in net location In Property table (NETSOURCE=path:/to/file/in/network/location). Use it property In SHORTCUT table in TARGET column ([NETSOURCE]\file.exe).

2) Create VBS script with follow content

InstPath = "path:/to/file/in/network/location"
Set Shell = CreateObject("WScript.Shell")
Set FSO = CreateObject ("Scripting.FileSystemObject")
StartMenue=Shell.SpecialFolders("AllUsersPrograms") & "\TEST"
If FSO.FolderExists(StartMenue) Then call FSO.DeleteFolder(StartMenue)
If Not FSO.FolderExists(StartMenue) Then Call FSO.CreateFolder(StartMenue)
Set link = Shell.CreateShortcut(Shell.SpecialFolders("AllUsersPrograms") & "\TEST\TEST.lnk")
link.Description = "TEST"
link.IconLocation = InstPath & "\TEST.exe"
link.TargetPath = InstPath & "\TEST.exe"
link.WorkingDirectory = InstPath

Create CustomAction and call this script from BINARY table (3142 type).

3) Use the script from 2 way to create shortcut in system. Install this link through FILE table. And create shortcut to this file through SHORTCUT table.

The first way is most correctly as for me.

I hope it help you.
yes Ok Thank Froyou SoMuch!