Mimic Windows' 'Run' window in .NET
Posted
by chaiguy
on Stack Overflow
See other posts from Stack Overflow
or by chaiguy
Published on 2010-05-20T00:19:01Z
Indexed on
2010/05/20
4:00 UTC
Read the original article
Hit count: 272
I would like to mimic the Run command in Windows in my program. In other words, I would like to give the user the ability to "run" an arbitrary piece of text exactly as would happen if they typed it into the run box.
While System.Diagnostics.Process.Start()
gets me close, I can't seem to get certain things like environment variables such as %AppData% working. I just keep getting the message "Windows cannot find '%AppData%'..."
© Stack Overflow or respective owner