Debugger target

michael-freidgeim-webjet edited this page Mar 22, 2018 · 10 revisions

Writes log messages to the attached managed debugger. See also System.Diagnostics.Debugger.Log

Supported in .NET, Silverlight and Mono

Configuration Syntax

  <target xsi:type="Debugger"
          header="Layout" />

Read more about using the Configuration File.


General Options

  • name - Name of the target.

Layout Options

  • footer - Footer. Layout
  • layout - Text to be rendered. Layout Required. Default: ${longdate}|${level:uppercase=true}|${logger}|${message}
  • header - Header. Layout

Performance Options

  • OptimizeBufferReuse - Reduce logging overhead, by allowing buffer reuse. Default: True

    Introduced with NLog v4.4.2. Default became True with NLog v4.5


From stackoverflow

  <target name="debugger" xsi:type="Debugger" layout="${logger}::${message}"/>

  <logger name="*" minlevel="Trace" writeTo="debugger" />

See Also

There is similar OutputDebugString-Target, that writes to OutputDebugString - that can be monitored by DebugView (And friends)

Clone this wiki locally
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.