Scripting Question

How can I launch an application using kScripting?

05/04/2015 1162 views
I have a VBS script to perform various post AutoDesk 2015 tasks such as install Autotable, move shortcuts, etc. The script is pushed via KAce Scripting. Part of that script I would like to have Revit.exe and ACA.exe launch. I would then login to the PC and visually verify several items in those applications. I want the script to launch the applications so I don't have to spend 5-10 min doing it manually. This process must execute on 70+ machines, the more I can automate certain steps, the lower my risk for re work is. 

The problem is the script appears to be launching revit.exe and aca.exe in another user's session. Maybe SYSTEM, not sure how to tell. I know this because when I push the script from Kace, and while logged into the targeted machine as a user with read/write access to C:\,  I see an Interactive Services Detection (IDS) prompt. I click the IDS prompt and click to view the message. I am then moved to what appears to be another user's session where revit.exe and aca.exe are both open and running. I have to click on the IDS prompt in that user's session to return to my normal session, where I can see the desktop icons etc. that I am normally used to seeing. 

How can I use VBS to launch an application in a specific user's session? (the admin in this case) Can Kace launch an application in s a specific user's session? 
Any other suggestions and/or observations are greatly appreciated. 
0 Comments   [ + ] Show comments


All Answers

By default scripts run in the system context.

If you use an Online KScript or online Shell Script you can specify the user in the "Windows Run As" section of the script configuration. This option is only available for Windows so be sure to only specify Windows in the operating systems section. For your specific scenario it might make sense to login to the computers first and then have the script setup to run as the logged in user.

Tip: Rather than logging into 70+ computers manually you can setup a script that sets the autologin registry keys and then restart the computers. Just remember to remove the autologin keys (with another script) when you are done. I use this technique for those times that I need to make manual changes to a lab. 
Answered 05/05/2015 by: chucksteel
Red Belt

  • Isn't there now a counter setting for autologon which avoids having to remove the entries?
    • You can set the AutoAdminLogon key to 0 and leave the username and password keys in place but I would consider that a security risk.
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