0

我问这个同事,只是为了确定它是否可能。

他有一个在系统帐户下运行的 vbscript 文件。部分脚本包含打开 Outlook 的调用,如下所示:

strCommand = WshShell.Run (Chr(34) & "C:\Program Files\Microsoft Office\Office14\Outlook.exe" & chr(34))

这可以按预期运行 Outlook,但他想要的只是该调用在登录用户的帐户下运行。

这可能吗?

谢谢马丁
_

4

2 回答 2

0

No you can't, because you'll then need the password of the logged on user. Plus you'll need to find out what the logged on user's account is in the first place (although that is relatively easy).

于 2012-08-31T08:18:34.527 回答
0

You can do this by using the runas command.

于 2012-08-30T19:31:58.333 回答