VBS required to install application silently and uninstall also:::::::::::::::::

Install CMD :

fpsetup.exe /Q


Uninstall CMD :

**********************To delete the below Keys for the proper uninstallation to happen *******************


[HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows]
"Device"="Microsoft XPS Document Writer,winspool,Ne00:"
"UserSelectedDefault"=dword:00000000 [HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows\SessionDefaultDevices] [HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows\SessionDefaultDevices\S-1-5-5-0-107752] *******************************************************************************************************************  

1.FreePDF (Remove only) -> Main application which also installs "Redirection Port Monitor"

    -> C:\Program Files\FreePDF_XP\fpsetup.exe /r /Q

2.Redirection Port Monitor

    -> C:\Windows\system32\unredmon.exe   (for 32bit)
    -> C:\Windows\system32\unredmon64.exe   (for 64bit)

1 Comment   [ + ] Show Comment


  • For proper uninstallation : Once I remove registry related to printera, RedMon cannot be uninstalled with the command line :

    -> C:\Windows\system32\unredmon.exe (for 32bit)
    -> C:\Windows\system32\unredmon64.exe (for 64bit)

    It shows RedMon is not installed but still ARP entry exists...
    This is wierd!!!!

    Any worked on this application or faced same issue in other applications???
Please log in to comment



You should be able to execute the fpsetup.exe and unredmon.exe commands using the WScript.Shell.Run method. Here's a reference for that: http://ss64.com/vb/run.html

For the registry, there are RegRead, RegWrite and RegDelete methods, also part of the WScript.Shell object. Here's a reference to RegDelete, which would be the one you would likely be using, but it links to the others: http://ss64.com/vb/regdel.html

Answered 12/30/2013 by: BHC-Austin
Fourth Degree Black Belt

  • The above is only part of the problem since, to uninstall software, the user will need to use an account with administrative privileges. That account - by definition - won't have direct access to that user's registry hive. The clunky way around that would be to divine the user's SID then loop through HKEY_USERS, blah, blah, blah. Since the poster clearly has no scripting expertise, it's a bit glib to suggest that it is as simply as using the registry methods of the Shell object.
    • Good point, I missed the fact that they were HKCU keys. Assuming this is run from KACE, it would be running under the built in system account. That being said, though, he could use Active Setup (as kludgy as it can be, anyway) to remove those entries for each user that logs in after the uninstall has taken place.

      My question is - why doesn't the uninstall of the application take care of those entries?
Please log in to comment
Answered 12/31/2013 by: ontari.ontari
Black Belt

Please log in to comment

Thanks all.. but I need a vbs which has to be run when placed in any directory.... command line is ???I used the below one :

'*************************** (1) Installation of the "Free PDF" **********************************************

Dim WshShell, sCurPath, strvalue

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

set objFS = CreateObject("Scripting.FileSystemObject")

sCurPath = objFS.GetParentFolderName(Wscript.ScriptFullName)

strCommand1 = chr(34) & sCurPath & "\fpsetup.exe" & chr(34) & " /Q"

'Msgbox strCommand1

WshShell.Run strCommand1, 0, True

Answered 01/02/2014 by: Scorp18
Orange Senior Belt

Please log in to comment
Answer this question or Comment on this question for clarity