Hello,

my putty uninstall code is:

********************************************
:$BeginUninstallScript
KillProcess('putty.exe',kpKillFirst+kpByFileName)/TS

ExecuteEx('"%ProgramFilesDir%\PuTTY\unins000.exe" /VERYSILENT /SUPPRESSMSGBOXES /NORESTART /SP-','_RC','3')/?/TS

If not %_rc%='0'
ExitProcEx(Failed,'Installation failed')
********************************************

it works good, but a messagebox will be shown during uninstall. If i click 'yes' uninstall will silent continue.

So, How can i suppress this message box?

a message box content asks the user, if he wants to save his sessions ...

Thanks for your help

mimo06

 

1 Comment   [ + ] Show Comment

Comments

  • Tis is a very old thread. But I am having the same issue. What kind if a script is that? I am having problems suppressing same msg box. Thank you.
Please log in to comment

Answers

0

hello rsubrata,

my solution consists of four steps:

!**********************************************
!Uninstall
: $BeginUninstallScript

!Step1

!Kill task putty.exe
KillProcess('putty.exe',kpKillFirst+kpByFileName)/TS

!Step2

!Delete links and Folder Putty
RemoveLink('PuTTY','','Programs\PuTTY',cgAsCommon)/TS
RemoveLink('Pageant','','Programs\PuTTY',)/TS
RemoveLink('PSFTP','','Programs\PuTTY',)/TS
RemoveLink('PuTTY Manual','','Programs\PuTTY',)/TS
RemoveLink('PuTTY Web Site','','Programs\PuTTY',)/TS
RemoveLink('PuTTYgen','','Programs\PuTTY',)/TS
RemoveFolder('Programs\PuTTY',cgAsCommon)/TS

!Step3

!Remove all files and the folder PuTTY: C:\Program Files 86)\PuTTY\                                  
Delete('%ProgramFilesDir%\PuTTY')/S/F/TS
RemoveDir('%ProgramFilesDir%\PuTTY')/S/TS

!Step4

!Remove folder PuTTY_is1 from the Registry, it is created during the installation.
RegDeleteKey('HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\PuTTY_is1','',)/TS
!Remove the sessions stored by the user, if they exist.
If RegKeyExists('HKEY_CURRENT_USER\Software\SimonTatham')
RegDeleteKey('HKEY_CURRENT_USER\Software\SimonTatham','',)/TU

!**********************************************

So, You can customize this solution for your needs.

 

Answered 01/09/2014 by: mimo06
Senior White Belt

  • hi mimo06, Thanks so much for your script and explanation. I got it now, that the script literally just to remove putty without the uninstaller executable. What I've been trying is still use the uninstaller executable with different parameters to suppress it. But this will work well. Thanks again Mimo06!
  • Hello Mimo,
    What kind of script is this? And could you help me giving some info about how to run this script?
Please log in to comment
0

since putty does not write to the registry, all you need to do is delete the putty directory and all files to uninstall, and maybe a shortcut if you created one.

Answered 11/14/2013 by: SMal.tmcc
Red Belt

Please log in to comment
0

It should simply work with the following command

C:\Program Files (x86)\PuTTY\unins000.exe /silent
Answered 11/15/2013 by: aragorn.2003
Red Belt

  • thanks for your help!
    @aragorn.2003: yes, it works like my solution, but the message box is still shown.
    That's why I tried the solution by SMal.tmcc and it works.
    @SMal.tmcc: putty write folowing folder PuTTY_is1 to the registry
    HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\PuTTY_is1
    For my putty-Uninstall i delete all Putty directory, links and the folder PuTTY_is1 from the registry.
    The Uninstall works now clean without messagebox.
    • @mimo06: do you happened to have the script of the uninstaller without the messagebox that works for you? I am still having the same issue with the messagebox popup. Thank you!
Please log in to comment
Answer this question or Comment on this question for clarity