DigicomDental
asked on
Need script to create shortcut on client desktops to helpdesk website
Hello Experts,
I been working on this for a while and have had little luck...probablly since I am a novice at scripting. I need a script that will create an icon (using a .ico) in "AllUsersPrograms" program files directory and pin it to the start menu. When users would click on this icon...it would take them to a helpdesk website on the internet. Ideally, I would like to deploy this with group policy. I found the code below and tried to adapt it to my situation but cound not get the icon to appear on the desktop. Just a generic IE icon appeared...but it worked otherwise. I also included some other code below that pins items to start menu that I found on an MSDN forum. Thanks a bunch! -John
I been working on this for a while and have had little luck...probablly since I am a novice at scripting. I need a script that will create an icon (using a .ico) in "AllUsersPrograms" program files directory and pin it to the start menu. When users would click on this icon...it would take them to a helpdesk website on the internet. Ideally, I would like to deploy this with group policy. I found the code below and tried to adapt it to my situation but cound not get the icon to appear on the desktop. Just a generic IE icon appeared...but it worked otherwise. I also included some other code below that pins items to start menu that I found on an MSDN forum. Thanks a bunch! -John
Dim oFSO, oLnk, WshShell, strDesktop
set WshShell = CreateObject("WScript.Shell")
strDesktop = WshShell.SpecialFolders("Desktop")
set oFSO = CreateObject("Scripting.FileSystemObject")
Set oLnk = oFSO.CreateTextFile(strDesktop & "\Poco Oil Website.url", True)
oLnk.WriteLine "[DEFAULT]"
oLnk.WriteLine "BASEURL=http://12.159.249.114"
Here, for example, is a script that pins the Windows Calculator (calc.exe) to the Start Menu:
Set objShell = CreateObject("Shell.Application")
Set objFolder = objShell.Namespace("C:\Windows\System32")
Set objFolderItem = objFolder.ParseName("calc.exe")
oLnk.WriteLine "[InternetShortcut]"
oLnk.WriteLine "URL=http://12.159.249.114/index.htm"
oLnk.WriteLine "IconFile=http://12.159.249.114/favicon.ico"
oLnk.Close
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.