Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: any way to pin .vbs such that the icon is retained?

09 May 2016   #1
maxseven

Windows 7 Home Premium 64bit 6.1 Build 7601 (SP1)
 
 
any way to pin .vbs such that the icon is retained?

Since you bumped this ancient thread I have to ask a related question:

I made a custom iTunes.VBS which in turn calls a RuniTunes.bat. I did this in order to Start and Stop Bonjour service which otherwise finds unusual times to load-up my event log with errors.

Both of these are at C:\, and when I try to pin the iTunes.VBS to the Taskbar, I can't make it do so with a custom icon e.g. the iTunes icon, it only gets a "Microsoft Windows Based Script Host" icon which I can't seem to change. Does anyone know how to make this work?

FWIW the .VBS I run looks like this:

Code:
Set WshShell = CreateObject("WScript.Shell")
WshShell.Run chr(34) & "C:\RuniTunes.bat" & Chr(34), 0
Set WshShell = Nothing
the the RuniTunes.bat is this:

Code:
net start "Bonjour Service"
net start "iPod Service"

"C:\Program Files\iTunes\iTunes.exe"

net stop "iPod Service"
net stop "Bonjour Service"
By this method I avoid having a cmd.exe window when I launch, and of course the services are started with iTunes and stopped again when I quit iTunes.

I currently have a shortcut to the C:\iTunes.VBS file sitting on my Desktop, with the nice, pretty iTunes icon having set Change icon in Properties. But now any way to pin it such that the icon is retained?


My System SpecsSystem Spec
.
09 May 2016   #2
Brink

64-bit Windows 10 Pro
 
 

Hello maxseven,

You could add "explorer" in front of the target path of the shortcut to be able to "Pin to taskbar", but you'll need to change the icon of the shortcut again afterwards first.

For example: explorer C:\iTunes.VBS
My System SpecsSystem Spec
09 May 2016   #3
maxseven

Windows 7 Home Premium 64bit 6.1 Build 7601 (SP1)
 
 

Quote   Quote: Originally Posted by Brink View Post
Hello maxseven,

You could add "explorer" in front of the target path of the shortcut to be able to "Pin to taskbar", but you'll need to change the icon of the shortcut again afterwards first.

For example: explorer C:\iTunes.VBS
Brink that is brilliant! Where do you learn such things!!!!!!?!!!!!

I did not have to change the icon--it just worked. THANK YOU!!!

My System SpecsSystem Spec
.

09 May 2016   #4
Brink

64-bit Windows 10 Pro
 
 

Perfect.
My System SpecsSystem Spec
Reply

 any way to pin .vbs such that the icon is retained?




Thread Tools Search this Thread
Search this Thread:

Advanced Search




Similar help and support threads
Thread Forum
wlan icon and sound icon on system tray not working
Good morning experts, Please help me since I dont know what to do to solve this. This mornig I started my laptop, after a few minutes the wifi disconnected and the yellow dot showed on the wifi icon. I tried to click on the icon but nothing happened. Tried to click click clik and nothing...
Network & Sharing
Network status icon and manage networks icon show different SSID
This is a problem that started with the last windows update (which included an update for my wireless network adapter which I have since rolled back). My setup is as follows: I have a dual band router. The 5Ghz band's SSID is (for example) Testg and the2.4 Ghz band's SSID is Testg2. When...
Network & Sharing
History is not retained in IE9
I never had a problem before with other versins of IE but now when I go check my history all it shows is where I have been on my computer, nothing about where I have been on the net. I uninstalled to make sure it was not a faulty install. I made sure I had enough disk space, I made sure it was not...
Browsers & Mail
Icon Help: Icons missing and replaced with Illustrator File Icon
Hey, I've been coming to this forum for a while now since I set up my Windows 7 system, the tutorials here are fantastic, and have helped me customized Windows 7 just the way I want it! :) except just after the last couple of days, I noticed that a few of the icons in the start menu were...
General Discussion
White 'File' icon showing over top of normal desktop icon
Really weird, see attachment.. Tried resetting the icon cache. It's like this on all of my desktop icons.. any ideas?
General Discussion


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 05:49.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App