简体   繁体   English

Debug.WriteLine如何将消息发送到输出窗口

[英]How does Debug.WriteLine send messages to output window

In other words I'm wondering how communication process is going on between visual studio and application launched in debug mode. 换句话说,我想知道在Visual Studio和在调试模式下启动的应用程序之间的通信过程是如何进行的。 I guess one of the trace listeners writes messages to a file and visual studio reads that file all the time. 我猜其中一个跟踪侦听器将消息写入文件,Visual Studio始终读取该文件。

It calls the Win32 API function OutputDebugString , which the debugger (Visual Studio) can listen for. 它调用Win32 API函数OutputDebugString ,调试器(Visual Studio)可以监听它。

See the corresponding source in .NET Core , for example. 例如,请参阅.NET Core中相应源

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM