Help! Problem running pst19upg.exe via SMS

  • Thread starter Thread starter static.chi.cubs
  • Start date Start date
S

static.chi.cubs

I have written a vbscript that will utilize pst19upg.exe to strip a
password from a pst file. (You may be asking yourself, why write a
script to do this when you can do it from the cmd line? Well, this
script is part of a much larger script, but I need this piece to work
first.)

Well, when I run the script out-of-pocket on my pc, everything works
great and the passwords are removed. However, when the script is
imported into an SMS package and pushed to my pc this way, the script
fails completely. I have checked to see if this is a permissions issue,
and that does not seem to be the case.

Any help would be GREATLY appreciated. I'm at a loss!

Here's is a small portion of the code:

Set wshShell = CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")

psxName = Left(fileName, (Len(fileName) - 1)) & "x"
bakName = Left(fileName, (Len(fileName) - 3)) & "bak"

If fso.FileExists("pst19upg.exe") Then
runString = "pst19upg -x " & Chr(34) & fileName & Chr(34)
traceOut = traceOut & "Exporting psx file... ( " & runString & "
)" & vbcrlf
'The following line works out-of-pocket, but fails with SMS
wshShell.Run runString, 1, true
If Not Err.Number = 0 Then
etc.
 
Have you tried a different parameter for the window state in the Run line?
Possibly a hidden state might work better
 
Yes, I have tried that and it did not yield a successful deployment.
However, I did find the root of the problem. It appears as though
Windows will not execute pst19upg unless: a) it is being run locally on
a given pc, or b) if being run on a remote server (this was my case),
one must map the server on his/her box prior to executing the file. I
chose to run the entire process (mapping, executing script,
disconnecting drive) from a batch file and everything works beautifully.
 
Back
Top