Network Location ShortCut.

Started by morenos1, December 06, 2013, 10:32:57 AM

Previous topic - Next topic

morenos1

When creating the following ShortCut:

name = "Location Name"
   
target = "\\server\share"

ShortCutMake( Environment("USERPROFILE") : "\NetHood\":name, target, "", "", 2, 0 )

How can I, later on, modify the ShorCut to point to a different location?


Thanks ....

Deana

Quote from: morenos1 on December 06, 2013, 10:32:57 AM
When creating the following ShortCut:

name = "Location Name"
   
target = "\\server\share"

ShortCutMake( Environment("USERPROFILE") : "\NetHood\":name, target, "", "", 2, 0 )

How can I, later on, modify the ShorCut to point to a different location?


Thanks ....

Use ShortCutEdit. You will also want to give the file the file extension .LNK:

Code (winbatch) Select
name = "Location Name"
lnkpath =  Environment("USERPROFILE") : "\NetHood\":name:".lnk"

target = "\\server\share"
ShortCutMake(lnkpath, target, "", "", 2, 0 )

newtarget =  "\\server2\share"
ShortCutEdit(lnkpath, newtarget, "", "", @normal, 0 )
Deana F.
Technical Support
Wilson WindowWare Inc.