We have just updated our small tool called devxexec.exe that allows to run a processes from different users credentials without logging off, switching accounts, or even knowing a password. New version is 1.12.
It is even possible to run a process under domain account without specifying its password!
Devxexec has command line interface and in can run in mute mode so it’s possible to use it from your own application.
Devxexec works on Windows Server 2003/2008, Windows Vista, Windows 7.
Unfortunately it doesn’t work on Windows XP.
Here are a few examples how to use it:
Run cmd under TrustedInstaller:
devxexec.exe /user:TrustedInstaller cmd
Run a program with parameters
devxexec.exe /user:System "cmd /c dir c:windows"
Run a program under the domain user account without password
devxexec.exe /user:Johan /domain:mydomain cmd