/build/static/layout/Breadcrumb_cap_w.png

How to call a VB script

Hi!

I am trying to call a VB script using our K1000.  The VB script was written by Microsoft to be used for the total removal of Office 2003. 

This is an online kscript, set to use domain admin privileges.

f5CtGK.png

Everything thinks it is happy, but the script never runs.  Any help would certainly be appreciated.

Thanks,
Matt

3 Comments   [ + ] Show comments
  • You have to put a check box in Wait for Completion so that the kbox can launch cscript.exe.

    Take a look under configuration polices. There is a wizard called Event log reporter. Run that wizard and save it. Then look at how it created the steps in the on Success area. That is how the KBOX can launch your vbs file. - nshah 9 years ago
    • Ok, I am still looking at this. I did add the "Wait for Completion" check. I will let you know if I get anywhere. Thanks! - argodzilla 9 years ago
  • Output Log

    Running as: administrator
    Creating process returned non-zero: C:\WINDOWS\System32\cscript.exe C:\Documents and Settings\All Users\Dell\KACE\kbots_cache\packages\kbots\71\OffScrub03.vbs: (0) The operation completed successfully.
    Error Code: 0
    Status Code: 1
    Activity Log

    Launching program: 'C:\WINDOWS\System32\cscript.exe' 'C:\Documents and Settings\All Users\Dell\KACE\kbots_cache\packages\kbots\71\OffScrub03.vbs' wait='true'
    Debug Log

    Running kbot: runkbot 71 1433273132
    CleanupDependencies: clean up dependencies in kbot directory C:\Documents and Settings\All Users\Dell\KACE\kbots_cache\packages\kbots\71
    CleanupDependencies: file OffScrub03.vbs is part of the dependency list, keep the file
    Kbot Config Info - Start
    id=71 name=Uninstall Office 2003 version=1433273123 type=policy
    execute disconnected=true logged_off=true
    execute events
    Kbot Config Info - Finish
    runkbot ----- launching [path='C:\WINDOWS\System32' program='cscript.exe' parms='C:\Documents and Settings\All Users\Dell\KACE\kbots_cache\packages\kbots\71\OffScrub03.vbs' wait='true'] ----- - argodzilla 9 years ago
  • This is being pointed at a windows XP SP3 VM. It is set in the online script to work on XP SP3. This is the same VM, I can run the script on using PSEXEC.... - argodzilla 9 years ago

Answers (2)

Posted by: anonymous_9363 9 years ago
Red Belt
0
Is the 'ul\administrator' account a member of the 'Administrators' group on 'nb-adminvm-mm'?

Comments:
  • Yes 'cl\administrator' is a member of the Administrators group on 'nb-adminvm-mm' - argodzilla 9 years ago
Posted by: anonymous_9363 9 years ago
Red Belt
0

First things first...take the KBox out of the picture.

Run the script on a target machine (you're obviously using VMs for testing, right?) If that works, then run the script against the box remotely using PSExec, set to run as System (the default). I'm not at all sure why you'd want to run a script to remove Office with Domain Admin privileges but your final test will be a re-run with those credentials. These last two executions will be emulating how the KBox operates but, being run from a command line, you'll be able to see what's happening.


Comments:
  • Ok thanks, I will give that a try. - argodzilla 9 years ago
  • So C:\Windows\System32>psexec -u cl\administrator \\nb-adminvm-mm cscript.exe /nologo c:\OffScrub03.vbs remotely launches the script when i supply the password.

    Yes I am testing on a VM.

    It threw an access denied message with the system account. - argodzilla 9 years ago
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ