smart Z
asked on
VB Script to Remove Old Version of Software and Run Installation
I would like to have a vbscript that will apply the first two commands to remove old version of softwares and run installation afterward.
MsiExec.exe /X{CF5E6448-70F9-4BE1-B1F9 -D14DB4872 C55} /QN /NORESTART
MsiExec.exe /X{F48F2DD4-DE70-4C4C-A20D -FCF771FAA 717} /QN /NORESTART
Set objShell = CreateObject("WScript.Shel l")
objShell.Run "Setup_PT.exe /s /v/qn", 1, False
MsgBox "Please note that your computer is in the process of receiving PT 2010 and will reboot. This is part of an update for all the engineers who have PT8.For any questions with regard to this update please contact the helpdesk."
MsiExec.exe /X{CF5E6448-70F9-4BE1-B1F9
MsiExec.exe /X{F48F2DD4-DE70-4C4C-A20D
Set objShell = CreateObject("WScript.Shel
objShell.Run "Setup_PT.exe /s /v/qn", 1, False
MsgBox "Please note that your computer is in the process of receiving PT 2010 and will reboot. This is part of an update for all the engineers who have PT8.For any questions with regard to this update please contact the helpdesk."
ASKER
RobSampson,
The script is good but just want to confirm these.
Do you know if SMS will miss any of the commands during the advertisement? I had one PC which I advertised a similar script bu the uninstall of the old programs did not happen but it did install the new program.
So not sure what happen. if I apply the script manually on the desktop it works fine.
Thanks,
The script is good but just want to confirm these.
Do you know if SMS will miss any of the commands during the advertisement? I had one PC which I advertised a similar script bu the uninstall of the old programs did not happen but it did install the new program.
So not sure what happen. if I apply the script manually on the desktop it works fine.
Thanks,
It shouldn't miss any, but if the product doesn't exist, or has a different product ID, it won't uninstall it. Also make sure the advertised script is running with Admin credentials. Maybe if it's configured to run as the local SYSTEM account it won't work either....depends on the product, and the location of the installation source.
Regards,
Rob.
Regards,
Rob.
ASKER
Yes I made sure the product with the same product ID is installed on the test desktop. I am not sure why it miss to remove the old version but the script is working fine.
Many thanks for your help and support.
Many thanks for your help and support.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Excellent
Regards,
Rob.
Open in new window