Run GUI with build in credentials

Ask your PowerShell-related questions, including questions on cmdlet development!
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
Posts: 6
Last visit: Sat May 08, 2021 3:45 pm
Has voted: 3 times

Run GUI with build in credentials

Post by DrKatzmann »

Hi all
I need to run af script (in a GUI) with the credentials of a service account. It is also necessary that there are no prompt. In other words, somehow I need to hardcode the credentials.

What is the best way to do this? The GUI wil be compiled to an *.exe file.


Posts: 14954
Last visit: Thu Oct 28, 2021 11:57 am
Answers: 14
Has voted: 3 times
Been upvoted: 11 times

Re: Run GUI with build in credentials

Post by jvierra »

You can set the package to run with alternate credentials when you package the script. See the documentation for instructions.