Solved

create shortcut with icon

Posted on 2014-04-03
1
445 Views
Last Modified: 2014-04-22
I am trying to roll out an internet shortcut with its own icon via sccm I am having trouble linking the icon to the shortcut. I have the below .vbs but it doesnt work can any one assist (I am not good with .vbs)

set WshShell = WScript.CreateObject("WScript.Shell" )
strDesktop = WshShell.SpecialFolders("AllUsersDesktop" )
set oShellLink = WshShell.CreateShortcut(strDesktop & "Your_Shortcut.lnk" )
oShellLink.TargetPath = " http://Server/website"
oShellLink.WindowStyle = 1
oShellLink.IconLocation = "C:WINDOWSsystem32shdoclc.dll"
oShellLink.Save
0
Comment
Question by:batesstaff
1 Comment
 
LVL 16

Accepted Solution

by:
Easwaran Paramasivam earned 500 total points
ID: 39975835
Icon location should be image format .ico. Say for example

oShellLink.IconLocation = "C:\WINDOWS\system32\bloh.ico"

Open in new window


It should work. You can provide DLL as IconLocation.
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
Whether you’re a college noob or a soon-to-be pro, these tips are sure to help you in your journey to becoming a programming ninja and stand out from the crowd.
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

25 Experts available now in Live!

Get 1:1 Help Now