Changing the icon of the *.url files 
Author Message
 Changing the icon of the *.url files

In Windows Explorer, set the icon for a .url file manually.  Then open the .url file in a text editor - it's just an INI style file format.  

The URLShortcut object doesn't support an IconLocation property.  You'll need to add it using FSO...

--
Michael Harris
Microsoft.MVP.Scripting
Seattle WA US
--

Quote:

> How can I change/set the icon of an internet URL?  I am able to create any
> URL using either of the sets of code below, BUT I can't change the icon
> for some reason.
> Trial1:
> var oUrlLink = ShellObj.CreateShortcut( quickLaunch[i] + "iSite.url" );
> oUrlLink.TargetPath = " http://www.*-*-*.com/ ";
> oUrlLink.Save();

> Trial2:
> var ts = fso.OpenTextFile( quickLaunch[i] + "iSite.url", ForWriting,
> false);
> ts.WriteLine("[InternetShortcut]");
> ts.WriteLine("URL= http://www.*-*-*.com/ ");



Wed, 29 Sep 2004 04:01:16 GMT  
 Changing the icon of the *.url files
Yes...

P.S. - What's with the HTML posts and {*filter*}sy font size <g>?

--
Michael Harris
Microsoft.MVP.Scripting
Seattle WA US
--

Quote:

> How can I add this using FSO?  Must I edit use OpenTextFile and edit the
> file adding the icon string or how?

> In Windows Explorer, set the icon for a .url file manually.  Then open the
> url file in a text editor - it's just an INI style file format.

> The URLShortcut object doesn't support an IconLocation property.  You'll
> need to add it using FSO...

> --
> Michael Harris
> Microsoft.MVP.Scripting
> Seattle WA US
> --


> > How can I change/set the icon of an internet URL?  I am able to create
> any
> > URL using either of the sets of code below, BUT I can't change the icon
> > for some reason.
> > Trial1:
> > var oUrlLink = ShellObj.CreateShortcut( quickLaunch[i] + "iSite.url" );
> > oUrlLink.TargetPath = " http://www.*-*-*.com/ ";
> > oUrlLink.Save();

> > Trial2:
> > var ts = fso.OpenTextFile( quickLaunch[i] + "iSite.url", ForWriting,
> > false);
> > ts.WriteLine("[InternetShortcut]");
> > ts.WriteLine("URL= http://www.*-*-*.com/ ");



Wed, 29 Sep 2004 04:42:33 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Change the icon of the *.url files?

2. Scripting URL Shortcut's Icon

3. Icon for a URL shortcut

4. Icon Definition with url link

5. Setting the .url shortcut icon

6. How can i change icons of HHCtrl component?

7. Any way to change IE icon?

8. Changing address bar icon?

9. Changing the icon to an hour glass?

10. How do I change the mouse pointer icon ?

11. Windows Change Icon Dialog

12. How can I change the mouse icon?

 

 
Powered by phpBB® Forum Software