+ Post New Thread
Results 1 to 15 of 15
O/S Deployment Thread, Uninstalling PDF Creator- running a cmd script in Technical; Hi all, New to this forum and indeed SCCM . I have managed to setup a one site SCCM deployment. ...
  1. #1

    Join Date
    Aug 2014
    Posts
    6
    Thank Post
    1
    Thanked 0 Times in 0 Posts
    Rep Power
    0

    Uninstalling PDF Creator- running a cmd script

    Hi all,

    New to this forum and indeed SCCM.

    I have managed to setup a one site SCCM deployment. 'Application' deployments seem to be working fine and as expected. All clients will Windows 7 64 bit.

    I am still testing things at the moment. My latest application to be installed is PDF Creator. I have installed this via a 'manual scripted' method as an 'Application'. This seems to install fine on the test clients.

    As far as I am aware there is no official MSI for this program, so I thought I'd try to uninstall the software, via the following .cmd script:

    "C:\Program Files (x86)\PDFCreator\unins000.exe" /verysilent /SUPPRESSMSGBOXES /NORESTART

    This works fine when run manually but I cannot seem to get it working via SCCM. I have searched the net and there has been discussion about batch scripts and system rights, etc. Perhaps it's something to do with 'what folder the script needs to execute?

    Can someone please let me know, the full and proper procedure using SCCM 2012 to uninstall this program.

    Many thanks.

  2. #2
    free780's Avatar
    Join Date
    Sep 2012
    Posts
    1,058
    Thank Post
    45
    Thanked 86 Times in 81 Posts
    Rep Power
    23
    In the path to the uninstall exe (within the deployment type) make sure you enter its as it would be on a 32 bit is. Then tick the box that says this is a 32 bit program on a 64 bit is. Sorry I can't remember the exact wording.

  3. #3

    mac_shinobi's Avatar
    Join Date
    Aug 2005
    Posts
    9,897
    Thank Post
    3,420
    Thanked 1,081 Times in 997 Posts
    Rep Power
    369
    @Arthur / @wagnerk / @SYNACK

    Found some articles via google but then found the uninstall string for PDF Creator which shows the same as what Sh500 is already using and when I tried to use msiexec /uninstall or similar I kept getting error messages

    Just wondering if you could shed some light on how to remove PDF Creator
    Last edited by mac_shinobi; 28th August 2014 at 08:27 AM.

  4. Thanks to mac_shinobi from:

    wagnerk (28th August 2014)

  5. #4

    Join Date
    Aug 2014
    Posts
    6
    Thank Post
    1
    Thanked 0 Times in 0 Posts
    Rep Power
    0
    Quote Originally Posted by free780 View Post
    In the path to the uninstall exe (within the deployment type) make sure you enter its as it would be on a 32 bit is. Then tick the box that says this is a 32 bit program on a 64 bit is. Sorry I can't remember the exact wording.
    Yep, I have that boxed checked already.

  6. #5
    free780's Avatar
    Join Date
    Sep 2012
    Posts
    1,058
    Thank Post
    45
    Thanked 86 Times in 81 Posts
    Rep Power
    23
    Is the path to c:\program files or ℅programfiles℅

  7. #6

    Join Date
    Aug 2014
    Posts
    6
    Thank Post
    1
    Thanked 0 Times in 0 Posts
    Rep Power
    0
    I've tried both of them, as well as C:\Program Files (x86)

  8. #7

    Join Date
    Aug 2014
    Posts
    6
    Thank Post
    1
    Thanked 0 Times in 0 Posts
    Rep Power
    0
    I am guessing I am missing out something fundamental in deploying a batch script via SCCM in general.

    Like I say, the 'uninstall.cmd' script that I have works fine when executed manually on the client PC.

  9. #8

    mac_shinobi's Avatar
    Join Date
    Aug 2005
    Posts
    9,897
    Thank Post
    3,420
    Thanked 1,081 Times in 997 Posts
    Rep Power
    369
    Is there some way to ensure that it runs with elevated access rights and would it make any difference if it is a .bat instead of a .cmd ?

  10. #9


    Join Date
    Feb 2007
    Location
    51.403651, -0.515458
    Posts
    9,388
    Thank Post
    241
    Thanked 2,815 Times in 2,077 Posts
    Rep Power
    813
    Quote Originally Posted by mac_shinobi View Post
    Is there some way to ensure that it runs with elevated access rights
    SCCM should run the batch file under the SYSTEM account.

    Quote Originally Posted by mac_shinobi View Post
    would it make any difference if it is a .bat instead of a .cmd?
    Extremely unlikely.

    Quote Originally Posted by Sh500 View Post
    I thought I'd try to uninstall the software, via the following .cmd script:

    Code:
    "C:\Program Files (x86)\PDFCreator\unins000.exe" /verysilent /SUPPRESSMSGBOXES /NORESTART
    If your batch file consists of just that command, you would be better off avoiding using batch files altogether and put the entire command in the "Uninstall program" box (similar to what is shown below).


  11. Thanks to Arthur from:

    Sh500 (29th August 2014)

  12. #10

    Join Date
    Aug 2014
    Posts
    6
    Thank Post
    1
    Thanked 0 Times in 0 Posts
    Rep Power
    0
    @Arthur,

    Entering the command directly does 'seem' to remove the software- but the client has a 'Removal Failed' as the status:


    SCCM_Error.jpg


    As far as I can see from the client, it has removed all directories - and in this case the PDF Creator instance in 'Devices and Printers' too.

  13. #11
    free780's Avatar
    Join Date
    Sep 2012
    Posts
    1,058
    Thank Post
    45
    Thanked 86 Times in 81 Posts
    Rep Power
    23
    Its probably the error code at the end of the uninstall. You can make sccm ignore behaviour based on exit code in the deployment type.

  14. #12


    Join Date
    Feb 2007
    Location
    51.403651, -0.515458
    Posts
    9,388
    Thank Post
    241
    Thanked 2,815 Times in 2,077 Posts
    Rep Power
    813
    Quote Originally Posted by Sh500 View Post
    Entering the command directly does 'seem' to remove the software - but the client has a 'Removal Failed' as the status:
    Error 0x87D00325 seems to be caused by the PDF Creator uninstaller (unins000.exe) launching another executable (%TEMP%\_iu14D2N.tmp) and then quiting. The second process is then used to remove everything in the %ProgramFiles(x86)%\PDFCreator folder (including unins000.exe).

    Quote Originally Posted by InnoSetup
    Because Windows doesn't allow programs to delete their own EXEs, the uninstaller creates and spawns a copy of itself in the TEMP directory. This "clone" performs the actual uninstallation, and at the end, terminates the original uninstaller EXE (at which point you get an exit code back), deletes it, then displays the "uninstall complete" message box (if it hasn't been suppressed with /SILENT or /VERYSILENT).
    SCCM thinks the uninstaller has completely finished when in fact it hasn't.

    The easiest solution is probably what @free780 suggested.

  15. #13
    free780's Avatar
    Join Date
    Sep 2012
    Posts
    1,058
    Thank Post
    45
    Thanked 86 Times in 81 Posts
    Rep Power
    23
    Either that or it needs /sp- /SUPPRESSMSGBOXES as well. Also it may be the detection rule you have in place for the application. I usually go for the display version registry entry with. HKEY_LOCAL_MACHINE\software\microsoft\windows\piec eofsoftware
    This entry should be deleted when the application is.

  16. #14

    Join Date
    Aug 2014
    Posts
    6
    Thank Post
    1
    Thanked 0 Times in 0 Posts
    Rep Power
    0
    Quote Originally Posted by free780 View Post
    Its probably the error code at the end of the uninstall. You can make sccm ignore behaviour based on exit code in the deployment type.
    @free780

    Can you explain how to do this please? I can see the default codes but not sure if they need to be modified or new ones added.

    I have just tried adding the extra 'suppress code' and changing the detection rule to a reg value. These still resulted in a 'software failure' message.


    On general note:

    Why is it that my .cmd script did not work and entering the code directly does? Is it something to with the script trying to run from a UNC path? I ask because, I tested a simple batch file that maps a network drive and that script also did not actually execute. It would just be good to know for future reference.
    Last edited by Sh500; 29th August 2014 at 02:29 PM.

  17. #15
    free780's Avatar
    Join Date
    Sep 2012
    Posts
    1,058
    Thank Post
    45
    Thanked 86 Times in 81 Posts
    Rep Power
    23
    returncode.JPG

    Try this under the deployment type.

SHARE:
+ Post New Thread

Similar Threads

  1. Anyone have an MSI for a PDF creator?
    By maniac in forum How do you do....it?
    Replies: 4
    Last Post: 15th March 2010, 11:21 AM
  2. "Run as" VB Script
    By storkyIV in forum Scripts
    Replies: 16
    Last Post: 27th January 2010, 09:53 PM
  3. Free PDF Creator Software
    By hillskill in forum Windows
    Replies: 11
    Last Post: 11th December 2009, 02:23 PM
  4. [Debian] cmd scripts , recording stuff?
    By browolf in forum *nix
    Replies: 5
    Last Post: 4th March 2009, 02:40 PM
  5. NTBackup doesn't seem to have a "Run Now" cmd
    By Grommit in forum Windows
    Replies: 4
    Last Post: 4th September 2007, 12:33 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •