Executable launches after running with runas

Support for all customers who have purchased a SAPIEN PowerShell Studio product license. This forum does not offer a response time guarantee.
Forum rules
DO NOT POST SUBSCRIPTION NUMBERS, LICENSE KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
User avatar
lincoln.gaudreau@accor.com
Posts: 2
Joined: Wed Jul 26, 2017 10:51 am

Executable launches after running with runas

Post by lincoln.gaudreau@accor.com » Mon Jun 11, 2018 9:42 am

Product, version and build: PowerShell Studio 2018 v5.5.152
32 or 64 bit version of product: 64bit
Operating system: Windows 10 1709
32 or 64 bit OS: 64bit

I've converted a script to a Windows Application using the SAPIEN PowerShell V2 Host (and also tried V3).

I've set the program with both a RunAs User and Impersonate user in different tests, and with each test the program will run correctly under multiple user account, but after exiting it will immediately launch a second time.

Is there a way to prevent this? What information do you need to assist with this?

Thank you!
packager - output settings.PNG
packager - output settings.PNG (23.83 KiB) Viewed 419 times
packager - engine.PNG
packager - engine.PNG (49.03 KiB) Viewed 419 times

User avatar
mxtrinidad
Site Admin
Posts: 213
Joined: Sun Mar 03, 2013 12:42 pm

Re: Executable launches after running with runas

Post by mxtrinidad » Mon Jun 11, 2018 10:48 am

Thank you for the identifying this issue.

I was able to replicate the condition. In general, it seems the execute the script twice.
When doing the "Build and Run" option, the script exe runs but when exiting, the script will run the second time.

Will be looking into it!
Thanks

User avatar
lincoln.gaudreau@accor.com
Posts: 2
Joined: Wed Jul 26, 2017 10:51 am

Re: Executable launches after running with runas

Post by lincoln.gaudreau@accor.com » Mon Jun 11, 2018 11:11 am

Great, thank you!