If the command prompt is not invoked correctly, you may need to add a "cmd/c " before the "echo".my $User="Somebody"; my $Pass="ThisIsInsecure!"; my $Program_to_run="notepad.exe"; my $result=`echo $Pass|RunAs /User:$User $Program_to_run`;
Theory is when you know something, but it doesn't work.
Practice is when
something works, but you don't know why it works.
Programmers combine Theory
and Practice: Nothing works and they don't know why.
-Anonymous
In reply to Re: Windows runas command
by NetWallah
in thread Windows runas command
by flintstone
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |