Dynamically create shortcut on desktop with custom icon in VBA

  • Thread starter Thread starter Brian G via AccessMonster.com
  • Start date Start date
B

Brian G via AccessMonster.com

Hey all,

I am intending on distributing an app that I would like to automatically
create a shortcut on the desktop in VB. So far pretty easy, the code is in a
number of posts here and pretty straightforward to do dynamically (this will
be largely distributed to network users so I cannot create a static shortcut).


Here's the twist, I know how to change an icon for a shortcut manually but
because the shortcut is created in the VB code I would like to know if there
is a means to change the icon in VB.

Any ideas would ge gratefully appreciated.
 
There's hope for this old boy yet.

Found it out in the wild....

As I said there are a number of posts with excellent scripts for creating the
shortcut dynamically in VB already on this website

All one needs to do to customize the shortcuts's icon is, (of course) create
the icon and then add

objLink.IconLocation = strFile2

where strFile2 is the location of that icon
 
Back
Top