cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Creo 4 Uninstall Piece by Piece

SOLVED
Highlighted
Aquamarine

Creo 4 Uninstall Piece by Piece

For Creo 3, our company batch file would uninstall each application one at a time, before doing an install for a new datecode. Each application was uninstalled separately for better support and flexibility with options.

For the Creo Agent, in Creo 3, we used the WMIC protocols to uninstall it. However, in Creo 4, that no longer works for the Platform Services, even though it is listed in WMIC.

Support suggests we use the new Install Manager batch file to uninstall everything at once. As I've said, I like the flexibility of doing it one at a time. I tried to even uninstall everything first and then wait to the end to use the Install Manager just for the Platform Services. However, when I do this, the Install Manager is removed, leaving the Platform Services still installed.

Does anyone have any inventive solutions to uninstall Platform Services on its own, using a batch command, besides using the Install Manager to uninstall everything at once?

Thanks in advance!

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Creo 4 Uninstall Piece by Piece

Everything you need to uninstall via a command line is in the registry. Open up regedit and then pick edit Find and what I do is type in something I think will be unique to Creo. So in the control panel from programs & features you see this:

4-27-2017 8-35-03 AM.jpg

I typed in datecode [f000] in the search field to get most of them.

4-27-2017 8-22-24 AM.jpg

My first hit was for Flexnet, what you want is the key that says UninstallString.

4-27-2017 8-21-43 AM.jpg

Every component should have one.

4-27-2017 8-22-58 AM.jpg

4-27-2017 8-24-03 AM.jpg

4-27-2017 8-24-35 AM.jpg

4-27-2017 8-25-00 AM.jpg

4-27-2017 8-25-22 AM.jpg

You’ll also want to do a search on the other items listed in the control panel.

To copy these commands out of the registry so you don’t have to retype them and possibly fat finger it, pick on the UninstallString key and pick Modify.

4-27-2017 8-25-57 AM.jpg

Hi-lite the value data field and RMB Copy.

4-27-2017 8-26-20 AM.jpg

Now you can paste that into notepad++ or whatever editor you use. like this:

"C:\Program Files\PTC\Creo 4.0\F000\InstallManager\uninstall.exe" -xmlPath "C:\Program Files\PTC\Creo 4.0\F000\Simulate\bin\pim\xml"

The advantage of using the uninstall string is it works much quicker than the WMIC commands.

If the untinsall string lists an msi you may want to add this to the end of the string. /qn REBOOT=ReallySuppress

For example:

  1. MsiExec.exe /X{0430FEB4-0CC6-4447-84D3-08443E4977CB} /qn  REBOOT=ReallySuppress
10 REPLIES 10

Re: Creo 4 Uninstall Piece by Piece

Everything you need to uninstall via a command line is in the registry. Open up regedit and then pick edit Find and what I do is type in something I think will be unique to Creo. So in the control panel from programs & features you see this:

4-27-2017 8-35-03 AM.jpg

I typed in datecode [f000] in the search field to get most of them.

4-27-2017 8-22-24 AM.jpg

My first hit was for Flexnet, what you want is the key that says UninstallString.

4-27-2017 8-21-43 AM.jpg

Every component should have one.

4-27-2017 8-22-58 AM.jpg

4-27-2017 8-24-03 AM.jpg

4-27-2017 8-24-35 AM.jpg

4-27-2017 8-25-00 AM.jpg

4-27-2017 8-25-22 AM.jpg

You’ll also want to do a search on the other items listed in the control panel.

To copy these commands out of the registry so you don’t have to retype them and possibly fat finger it, pick on the UninstallString key and pick Modify.

4-27-2017 8-25-57 AM.jpg

Hi-lite the value data field and RMB Copy.

4-27-2017 8-26-20 AM.jpg

Now you can paste that into notepad++ or whatever editor you use. like this:

"C:\Program Files\PTC\Creo 4.0\F000\InstallManager\uninstall.exe" -xmlPath "C:\Program Files\PTC\Creo 4.0\F000\Simulate\bin\pim\xml"

The advantage of using the uninstall string is it works much quicker than the WMIC commands.

If the untinsall string lists an msi you may want to add this to the end of the string. /qn REBOOT=ReallySuppress

For example:

  1. MsiExec.exe /X{0430FEB4-0CC6-4447-84D3-08443E4977CB} /qn  REBOOT=ReallySuppress

Re: Creo 4 Uninstall Piece by Piece

A couple of questions:

  1. Is the gibberish value the same for all computers? (MsiExec.exe /I{319DF626-D04C-4CF6-B4F7-27080294A4A0})
  2. Do these gibberish values change each datecode or version? I would assume so. So every version I would need to go through this process again? We could have users, who barely use the software and be 2, 3 or even 7 versions behind on the software. The batch would need to be smart enough to know that and account for that. I'm a little concerned that I would need to check for each one of these MsiExec values if they change for each iteration.

Thanks!

Re: Creo 4 Uninstall Piece by Piece

Finished Editing last post. Thanks again.

Re: Creo 4 Uninstall Piece by Piece

The uninstall string is the same for all machines, but it is unique to the version of the software installed. F000 will be different than M010.

Some will have two uninstall strings. For example the Platform Services has a weird name, and it has a QuietUninstallString and a UninstallString that will require user interaction.

4-27-2017 9-27-51 AM.jpg

unfortunately not every PTC product has a nice uninstall string. I typically have to use wmic for those.

Mathcad 15 I use this:

rem ** Uninstall any existing version of Mathcad 15

wmic product where (name like "%%Mathcad 15%%") call uninstall /nointeractive

Mathcad Prime I use this:

rem ** Uninstall any existing version of Mathcad Prime

wmic product where (name like "%%Mathcad Prime%%") call uninstall /nointeractive

Creoview I use this:

rem ** Kill running processes so the installer will not reboot the machine after the install.

tskill Acrobat

tskill AcroRd32

tskill pview

tskill productview

rem ** Remove all current versions of Creo View

wmic product where (name like "%%Creo View%%") call uninstall /nointeractive

Re: Creo 4 Uninstall Piece by Piece

You can use Olaf code snipet to check to see what's install and then just run the appropriate uninstall command.

rem ** Check and set current build

set CREOVERSION=Unknown

rem ** CREOVERSION will be set to the alphabetical latest folder

FOR /F %%i IN ('dir /AD /B /ON "%CreoPath%\F*" "%CreoPath%\M*"') DO (set CREOVERSION=%%i)

rem ** Error message if no build folder has been found

IF NOT EXIST "%CreoPath%\%CREOVERSION%\Common Files"  echo ERROR: No valid Creo 3.0 build found in %CreoPath% (%CREOVERSION%)

Re: Creo 4 Uninstall Piece by Piece

I only use the WMIC where I couldn't use the silent method dictated in the documentation ("%creo_load_point%\%Installed_Date_Code%\Simulate\bin\uninstall.lnk" ). Based on what you've said above, I've found the below MsiExec for the programs I've used WMIC:

Creo View 4.0 - MsiExec.exe /I{319DF626-D04C-4CF6-B4F7-27080294A4A0}

MathCAD Prime 4.0 - MsiExec.exe /X{76F154D2-2092-41FC-956C-DC0B79D2B8CA}

Creo View Express 4.0 - MsiExec.exe /X{C71E9025-8D0D-4AA6-8F55-23D0ED20392E}

Thumbnail Viewer 4.0 - MsiExec.exe /X{7B71C02C-89C9-462C-8F95-11D13F9A5842}

Diagnostic Tools 4.0 - MsiExec.exe /X{F35B2487-77CD-4A91-A83C-DD64D7D5C663}

MKS Platform Components 9.X - MsiExec.exe /I{30276636-0000-0905-9ABB-000BDB5CF35D}

Platform Services - MsiExec.exe /X{5245CF2D-235F-4794-A2EE-C23E3261CC5F}

For the above, it sounds like you would still use the WMIC for better control. Is that correct? I guess I would only need the Platform Services for my initial query.

Re: Creo 4 Uninstall Piece by Piece

One more idea here.

We use LANDesk to let the users self deploy the software. LANDesk will run the install as local system, and then it can run a post install script as the user that deployed the software.

I use that second script run as the user to configure the software for that user and to record the user, machine, and date that the software was deployed.

Here are the last few lines of the post install script:

rem ** Record Computer & User info, and open a message to user

call "\\<servername>\<sharename>\<path>\record_computer_Creo3-110.cmd"

EXIT /B 0


The record computer batch file looks like this:

rem ********* Add to Log File: results, Machine, User, OS bitness, date, & time ***********

rem ** do a wmi query to get the computer model set it to the "machine" variable

FOR /F "tokens=2 delims==" %%A IN ('WMIC csproduct GET Name /VALUE ^| FIND /I "Name="') DO SET machine=%%A

for /F "tokens=*" %%n in ('wmic PATH Win32_videocontroller GET description ^| findstr "NVIDIA AMD"') do set GPU_NAME=%%n

FOR /F "tokens=2 delims==" %%A IN ('WMIC cpu GET Name /VALUE ^| FIND /I "Name="') DO SET machinecpu=%%A

rem ** Check and set current build

set CREOVERSION=Unknown

rem ** CREOVERSION will be set to the alphabetical latest folder

FOR /F %%i IN ('dir /AD /B /ON "%CREO3PATH%\F*" "%CREO3PATH%\M*"') DO (set CREOVERSION=%%i)

rem ** Check for 64bit OS

if exist C:\Windows\SysWOW64 (Set bitness=64_Bit) ELSE (Set bitness=32_Bit)

if exist d:\ptc  (Set DriveSetUp="MULTI DRIVE") ELSE (Set driveSetUp="SINGLE DRIVE")

set OUTNAME=Creo3-110_%username%_%computername%_Info_%date:~10,4%-%date:~4,2%-%date:~7,2%.txt

rem ** Output information about the computer to a file 

echo %username% > %USERPROFILE%\Documents\%OUTNAME%

echo %computername% >> %USERPROFILE%\Documents\%OUTNAME%

echo %machine% >> %USERPROFILE%\Documents\%OUTNAME%

echo %machinecpu% >> %USERPROFILE%\Documents\%OUTNAME%

systeminfo | findstr /C:"Total Physical Memory" >> %USERPROFILE%\Documents\%OUTNAME%

echo %GPU_NAME% >> %USERPROFILE%\Documents\%OUTNAME%

systeminfo | findstr /B /C:"OS Name" /C:"OS Version"  >> %USERPROFILE%\Documents\%OUTNAME%

echo %bitness% >> %USERPROFILE%\Documents\%OUTNAME%

echo Creo=%CREOVERSION% >> %USERPROFILE%\Documents\%OUTNAME%

echo Drive     Free Space    Size >> %USERPROFILE%\Documents\%OUTNAME%

wmic /node:"%COMPUTERNAME%" LogicalDisk Where DriveType="3" Get DeviceID,FreeSpace,Size|find /I "c:" >> %USERPROFILE%\Documents\%OUTNAME%

wmic /node:"%COMPUTERNAME%" LogicalDisk Where DriveType="3" Get DeviceID,FreeSpace,Size|find /I "d:" >> %USERPROFILE%\Documents\%OUTNAME%

wmic /node:"%COMPUTERNAME%" LogicalDisk Where DriveType="3" Get DeviceID,FreeSpace,Size|find /I "e:" >> %USERPROFILE%\Documents\%OUTNAME%

echo %DriveSetUp% >> %USERPROFILE%\Documents\%OUTNAME%

getmac /v >> %USERPROFILE%\Documents\%OUTNAME%

echo ===== >> %USERPROFILE%\Documents\%OUTNAME%

@echo off

setlocal

set varcounter=0

set wmicmd="wmic NICCONFIG WHERE IPEnabled=true GET IPAddress"

for /f "tokens=1 delims={, skip=1" %%a in ('%wmicmd%') do call :SETVAR %%a

endlocal

goto :COPYFILE

:SETVAR

set /a varcounter=%varcounter% + 1

if not {%1}=={} (

    echo NIC %varcounter% address is {%1} >> %USERPROFILE%\Documents\%OUTNAME%

    set NIC%varcounter%=%1

)

goto :COPYFILE

:COPYFILE

copy %USERPROFILE%\Documents\%OUTNAME% "\\<servername>\<sharename>\System Info\."


I get a folder with text files that are named like this like this:

Creo3-110_<UserName>_<MachineName>_Info_2017-03-23.txt

Re: Creo 4 Uninstall Piece by Piece

The uninstall string is faster. I use it where it exist. If there isn't an uninstall string I try to use wmic. If that fails I use EMCO MSI Builder to create an msi to do the uninstall.

Re: Creo 4 Uninstall Piece by Piece

Thanks for your help.