Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Whats the best way to create a desktop shortcut ?
Message
 
 
À
17/01/2001 20:43:48
Information générale
Forum:
Visual FoxPro
Catégorie:
Installation et configuration
Divers
Thread ID:
00464645
Message ID:
00465523
Vues:
14
Hi Alex!

Any ideas how to create a shortcut link w/o a drive designator. My objective is to place a shortcut on a CD's root, but obviously there's no way of knowing the drive letter it will be. (e.g. target: "\ie5\win32\en\ie5setup.exe" )

Thanks, I need some fresh ideas!
oWsh = CreateObject("WScript.Shell")
cDesktopDir = oWsh.SpecialFolders("Desktop")
oLnk = oWsh.CreateShortcut(cDesktopDir + "\\Shortcut to Notepad.lnk")
oLnk.TargetPath = cDesktopDir + "\\notepad.lnk"
oLnk.Save()
-michael

My brain hurt like a warehouse, it had no room to spare, I had to cram so many things to store everthing in there. - David Bowie
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform