Run As on Remote Computer

by Kottees at 2013-03-04 06:02:15

Hello Experts,

I’m doing an automation to fetch information from remote computers, I’m able to connect remote computers and run "run as" but it stuck in a place where we should provide credentials.

I would like to provide remote computer password in the ps1 file itself. Could you please show me some direction?

Thanks in advance.
by DexterPOSH at 2013-03-04 09:03:30
Hi Kottees,

When you say you are able to connect to the remote computer, does it mean you are using PowerShell Remoting ?
If it does then before connecting using Enter-PSSession you can use the -credential parameter to specify the alternate creadentials.

Hope it helps
by Kottees at 2013-03-07 02:09:26
Thank you Dexter, will try that.