Werbung: SecurityConsole.de verwaltet Ihre Computer mit Security Essentails aus der Cloud!
30 Tage kostenfrei testen und 20% Rabatt für Ihre Bestellung mit Promocode: WBF2685582
(Promocode gültig bis 31.12.2011)

Group:  English: Windows Server » microsoft.public.windows.server.scripting
Thread: How do I copy an icon to multiple client machines?

HTVi
TV Discussion Newsgroups

How do I copy an icon to multiple client machines?
TigerBite 5/11/2007 8:32:00 PM
I'd like to script a way to copy an icon to multiple client machines. I'm
very new to this scripting thing, and I've come to a dead end. Any help
would be greatly appreciated.


Re: How do I copy an icon to multiple client machines?
"Al Dunbar" <AlanDrub[ at ]hotmail.com.nospaam> 5/12/2007 3:46:44 AM
There are a number of ways to do that kind of thing - how, precisely, do you
want it to work, and what have you tried so far?

And an "icon"? Do you mean an icon file or a shortcut? Where do you want
this to go - each individuatl user's desktop, or to the all users desktop?

/Al

"TigerBite" <TigerBite[ at ]discussions.microsoft.com> wrote in message
news:8BB996C1-5DA7-4986-8FD5-37F4A597E031[ at ]microsoft.com...
[Quoted Text]
> I'd like to script a way to copy an icon to multiple client machines. I'm
> very new to this scripting thing, and I've come to a dead end. Any help
> would be greatly appreciated.
>
>


Re: How do I copy an icon to multiple client machines?
TigerBite 5/15/2007 4:37:00 PM
I currently have figured out a way to copy a shortcut to a website onto all
users desktops, but I want to customize the icon. The custom icon will not
work unless the icon file (.ico) is already on each of the users boxes. I am
open to any way to do this. Below is what I have to put the shortcut onto
desktops. Thanks.

set WshShell = WScript.CreateObject("WScript.Shell")
strDesktop = WshShell.SpecialFolders("Desktop")
set oShellLink = WshShell.CreateShortcut(strDesktop & "\Waldo Work
Requests.lnk")
oShellLink.TargetPath = "http://fmswr.com?LID=CE67DA230ed83396F2mPs2E28871"
oShellLink.WindowStyle = 1
oShellLink.IconLocation = "C:\Program Files\Internet Explorer\IEXPLORE.EXE, 0"
oShellLink.Description = "Work Request Site"
oShellLink.Save


"Al Dunbar" wrote:

[Quoted Text]
> There are a number of ways to do that kind of thing - how, precisely, do you
> want it to work, and what have you tried so far?
>
> And an "icon"? Do you mean an icon file or a shortcut? Where do you want
> this to go - each individuatl user's desktop, or to the all users desktop?
>
> /Al
>
> "TigerBite" <TigerBite[ at ]discussions.microsoft.com> wrote in message
> news:8BB996C1-5DA7-4986-8FD5-37F4A597E031[ at ]microsoft.com...
> > I'd like to script a way to copy an icon to multiple client machines. I'm
> > very new to this scripting thing, and I've come to a dead end. Any help
> > would be greatly appreciated.
> >
> >
>
>
>
Re: How do I copy an icon to multiple client machines?
"Al Dunbar" <AlanDrub[ at ]hotmail.com.nospaam> 5/16/2007 12:27:10 AM
You are already creating a file on their desktop, just create the .ico
file - by copying it there. Something like this, perhaps:

set WshShell = WScript.CreateObject("WScript.Shell")
strDesktop = WshShell.SpecialFolders("Desktop")

strAppData = WshShell.SpecialFolders("AppData")
set FSO = CreateObject("WScript.Shell")
FSO.copyfile "\\server\share\fmswr.ico", strAppData, true

set oShellLink = WshShell.CreateShortcut(strDesktop & "\Waldo Work
Requests.lnk")
oShellLink.TargetPath =
"http://fmswr.com?LID=CE67DA230ed83396F2mPs2E28871"
oShellLink.WindowStyle = 1

oShellLink.IconLocation = strAppData & "\fmswr.ico, 0"

oShellLink.Description = "Work Request Site"
oShellLink.Save

The .ico file is copied from a server using its UNC. In your environment
there might be a mapped drive available. The file is copied to the
application data folder in the user's profile because he might not have the
necessary access to copy it to some common location.

This assumes that the user is going to run the script himself, either
directly or as part of a logon script. Alternately, you could run this
script from a workstation using an account that has administrator privileges
on the workstations, and create/copy the files to the desktop and
application data folder in the all users profile.


/Al

"TigerBite" <TigerBite[ at ]discussions.microsoft.com> wrote in message
news:E4DAA01D-1E5C-48AE-8A3C-474A2AB1B4D3[ at ]microsoft.com...
[Quoted Text]
>I currently have figured out a way to copy a shortcut to a website onto all
> users desktops, but I want to customize the icon. The custom icon will
> not
> work unless the icon file (.ico) is already on each of the users boxes. I
> am
> open to any way to do this. Below is what I have to put the shortcut onto
> desktops. Thanks.
>
> set WshShell = WScript.CreateObject("WScript.Shell")
> strDesktop = WshShell.SpecialFolders("Desktop")
> set oShellLink = WshShell.CreateShortcut(strDesktop & "\Waldo Work
> Requests.lnk")
> oShellLink.TargetPath =
> "http://fmswr.com?LID=CE67DA230ed83396F2mPs2E28871"
> oShellLink.WindowStyle = 1
> oShellLink.IconLocation = "C:\Program Files\Internet
> Explorer\IEXPLORE.EXE, 0"
> oShellLink.Description = "Work Request Site"
> oShellLink.Save
>
>
> "Al Dunbar" wrote:
>
>> There are a number of ways to do that kind of thing - how, precisely, do
>> you
>> want it to work, and what have you tried so far?
>>
>> And an "icon"? Do you mean an icon file or a shortcut? Where do you want
>> this to go - each individuatl user's desktop, or to the all users
>> desktop?
>>
>> /Al
>>
>> "TigerBite" <TigerBite[ at ]discussions.microsoft.com> wrote in message
>> news:8BB996C1-5DA7-4986-8FD5-37F4A597E031[ at ]microsoft.com...
>> > I'd like to script a way to copy an icon to multiple client machines.
>> > I'm
>> > very new to this scripting thing, and I've come to a dead end. Any
>> > help
>> > would be greatly appreciated.
>> >
>> >
>>
>>
>>


Home | Search | Terms | Imprint Contact
Newsgroups Reader - provided by WiredBox.Net
Suche nach Orten, Städten, Postleitzahlen, Vorwahlen, Kfz-Kennzeichen