Jump to content

Silent removal of the Google and Yahoo! Toolbars


Plamdi

Recommended Posts

Another first, from yours truly. I prefer to use the original installation files using official switches and then to move the icons and make other changes manually. Some programs, such as CCleaner install the Yahoo Toolbar when run silently. You can use these scripts to silently remove the toolbars. 7 lines of script (awwe :) ), errorlevel returned when used with cscript (of course, you can use either CSCRIPT or WSCRIPT with this one).

Do you need any other silent un-installations? Just LMK!

Available combined into one file, or as seperate files:

' (c) 2006 Plamdi.com. This file silently uninstalls the Google and Yahoo! Toolbars.
Option Explicit:On Error Resume Next
Dim WshShell,a,i:i=0:Set WshShell=WScript.CreateObject("WScript.Shell")
a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{2318C2B1-4965-11d4-9B18-009027A5CD4F}\UninstallString")
If a<>"" Then WshShell.Run(a&" /S"),1,True:i=i+1
a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Yahoo! Companion\UninstallString")
If a<>"" Then WshShell.Run(""""&a&""" /S"),1,True:i=i+1
WshShell=Nothing:Wscript.Quit(i)

Save as REMTOOLB.VBS

' (c) 2006 Plamdi.com. This file silently uninstalls the Yahoo! Toolbar.
Option Explicit:On Error Resume Next
Dim WshShell,a,i:i=0:Set WshShell=WScript.CreateObject("WScript.Shell")
a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Yahoo! Companion\UninstallString")
If a<>"" Then WshShell.Run(""""&a&""" /S"),1,True:i=1
WshShell=Nothing:Wscript.Quit(i)

Save as REMYAHOO.VBS

' (c) 2006 Plamdi.com. This file silently uninstalls the Google Toolbar.
Option Explicit:On Error Resume Next
Dim WshShell,a,i:i=0:Set WshShell=WScript.CreateObject("WScript.Shell")
a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{2318C2B1-4965-11d4-9B18-009027A5CD4F}\UninstallString")
If a<>"" Then WshShell.Run(a&" /S"),1,True:i=1
WshShell=Nothing:Wscript.Quit(i)

Save as REMGOOGLE.VBS

And here's a tip - if you plan on running this file from the HDD rather than the CD/DVD, you could add these lines:

Dim fso:Set fso=CreateObject("Scripting.FileSystemObject")
fso.DeleteFile(WScript.ScriptFullName)

and script would automatically self-destruct. You would add the lines anywhere after the first line (of code) and before the last line.

* Slight modification, the script now waits for the uninstaller to complete before terminating - which is probably better if you're going to use cscript as the uninstaller will finish before processing the next command.

Edited by Plamdi
Link to comment
Share on other sites


Can you do one for Google Toolbar aswell :)
Done. The Google toolbar's uninstaller actually already has the silent switch in it, but it doesn't hurt to add it again, just to be sure ;)
Link to comment
Share on other sites

  • 1 year later...

Plamdi Thank you for the information. This was very useful, due to the issues we were having I used alot of your ideas to expand this to include Ask Toolbar, Ask toolbar (ASKPBAR one I think), Weather Channel, and the Aol Toolbar. Here is my modified verision. Please be nice, this was my very first vb script:

'This file silently uninstalls the Google, Yahoo!, Ask, and AOL Toolbars. This also removes Weather Channel Desktop.

'Option Explicit

Set Shell=WScript.CreateObject("Shell.Application")

Shell.MinimizeAll

On Error Resume Next

Dim WshShell,a,i

i=0

Set WshShell=WScript.CreateObject("WScript.Shell")

Set Shell=WScript.CreateObject("Shell.Application")

'Begin Script

'This Removes the Google ToolBar

a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{2318C2B1-4965-11d4-9B18-009027A5CD4F}\UninstallString")

If a<>"" Then

WshShell.Run(a&" /S"),1,True

i=i+1

end if

'This Removes the Yahoo Toolbar

a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Yahoo! Companion\UninstallString")

If a<>"" Then

WshShell.Run(""""&a&""" /S"),1,True

i=i+1

end if

'This Removes the bundled Ask ToolBar

a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\AskPBar Uninstall\UninstallString")

If a<>"" Then

WshShell.Run(a),1,False

i=i+1

Wscript.sleep 3000 'pause for 3 seconds

WshShell.SendKeys "{TAB}"

WshShell.SendKeys "%Y"

Wscript.sleep 1000

WshShell.SendKeys "{ENTER}"

end if

'This Removes the Weather Channel Desktop

a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\The Weather Channel Desktop\uninstallstring")

If a<>"" Then

WshShell.Run(""""&a&""" /S"),1,False

i=i+1

Wscript.sleep 5000 'pause for 5 seconds

WshShell.SendKeys "{DOWN}"

WshShell.SendKeys "{DOWN}"

WshShell.SendKeys "{DOWN}"

WshShell.SendKeys "{ENTER}"

Wscript.sleep 2000

WshShell.AppActivate "Parature Header - Microsoft Internet Explorer"

WshShell.SendKeys "%F"

WshShell.SendKeys "C"

end if

'This Removes the AOL Toolbar

a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\AOL Toolbar\Uninstallstring")

If a<>"" Then

WshShell.Run(a&" /S"),1,True

i=i+1

end if

'This removes the Ask Toolbar

a=WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Ask Toolbar for Internet Explorer_is1\uninstallString")

If a<>"" Then

WshShell.Run(a&" /SILENT"),1,True

i=i+1

end if

Wscript.sleep 15000

'This Ends the Script

WshShell=Nothing:Wscript.Quit(i)

Edited by chrismholmes
Link to comment
Share on other sites

  • 3 months later...

Thanks for the contribution, chrismholmes, however I don't reccomend simpkly using sendkeys and sleep the way you have. 9 times out of 10 it'll probably work fine, however I have written a far better program for this purpose that works on a far better level. It is called OEM Installer, and you'll find it amung my recent post that includes all of my VBS contributions to date! It is still VBS based, but is much easier to add programs to, and is much less prone to errors. You could piggy-back the programs, if you wanted to, by writing (for instance) adding the remove weather channel check into the REMTOOLB.VBS file in the way you have, except instead of then running its own little script using send keys it launches OEM Installer to do the automated-uninstall-script.

Here's pseudocode to illistrate what I mean:

<REMTOOLB.VBS>
<IF GOOGLE TOOLBAR INSTALLED> - Launch google toolbar uninstaller using silent switch.
<IF YAHOO TOOLBAR INSTALLED> - Launch yahoo toolbar uninstaller using silent switch.
<IF AOL TOOLBAR INSTALLED> - Launch aol toolbar uninstaller using silent switch.
<IF ASK TOOLBAR INSTALLED> - Launch ask toolbar uninstaller using silent switch.
<IF Weather Channel Desktop INSTALLED> - Lauch OEM Installer to uninstall program.
<OEM INSTALLER>
Check what program I run from commandline.
Open INI file to see how I run this program.
Run program and automate the process as layed out in INI file.
Terminate when my program has terminated, or script instructs me to.

The post with OEM Installer is here, I suggest giving it a go it's really easy, and there are even some working examples in there to get you started.

Edited by Plamdi
Link to comment
Share on other sites

i just want to point out that some programs can be downloaded without any toolbars. CCleaner has another installer without additional languages and without the yahoo toolbar, look at the "Other build" links in their download page.

If i ever need to remove a toolbar, i will look at this scripts. thanks.

Link to comment
Share on other sites

  • 4 months later...

Thank you, all of you guy for the tips. I tried a number of solutions for a silent uninstall of Google toolbar, but none did a truly silent (hidden) uninstall for me. After a bit of poking around, I found this command removes the Google Toolbar properly and quickly, and is completely silent and hidden:

MsiExec.exe /X{DBEA1034-5882-4A88-8033-81C4EF0CFA29} /qn

Have any of you tried it?

Edited by badrad600
Link to comment
Share on other sites

  • 6 months later...
Thank you, all of you guy for the tips. I tried a number of solutions for a silent uninstall of Google toolbar, but none did a truly silent (hidden) uninstall for me. After a bit of poking around, I found this command removes the Google Toolbar properly and quickly, and is completely silent and hidden:

MsiExec.exe /X{DBEA1034-5882-4A88-8033-81C4EF0CFA29} /qn

Have any of you tried it?

This is using a product code to remove Google toolbar. Each version will have a different product code. Unfortunately I don't think google sets a registry key like yahoo does for any version. You will need to know the product key for each version of the google toolbar you want to remove.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...