Utility with unredirectable output (Windows)

我的未来我决定 提交于 2019-11-27 14:52:31

There's nothing particularly magical about it. Although the C library defaults to sending output to the standard output handle, there's no obligation for a program to do so; you can always open your own handle to the console output device (CONOUT$) instead.

See the documentation on CreateFile for more information about console devices.

In terms of capturing the output, you may be able to do something with ReadConsoleOutput and friends, but it isn't straightforward.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!