Take the 2-minute tour ×  I'm writing a console tool. Without
privileges elevating for UAC support (manifest file), calling
this tool from command prompt (cmd.exe) or console file manager
(like far.exe) opens it in the same window, writes its output to
the same window, etc.  But now, when manifest file was added, a
new console windows is created for tool after UAC request
dialog, so tool's output is written there, and window closes. No
purpose for such tool being console.  How to fix that? What
workarounds are there?  share|improve this question add comment
1 Answer  There is no way to "fix" that, as far as I know. This
behavior is by design and is intended to ensure that any command
line tool you elevate is not affected by any path modifications
in the non-elevated command-line.  The idea is that in a normal
day's work, people run any programs on their machines. These
programs might modify the path for the user, so that a folder
contains a malicious program named reg.exe for example is put
before c:\windows