title: Have NLog write to console
body: <p>I'm pretty new to NLog. I have a .NET framework console application using NLog. I hope to configure NLog to write the log to console directly. I installed NLog and the NLog.Config <a href="https://packages.nuget.org/packages/NLog.Config/" rel="noreferrer">NuGet package</a>, with the following content in nlog.config:</p>
  <pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot; ?&gt;
  &lt;nlog xmlns=&quot;http://www.nlog-project.org/schemas/NLog.xsd&quot;
        xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;
        xsi:schemaLocation=&quot;http://www.nlog-project.org/schemas/NLog.xsd NLog.xsd&quot;
        autoReload=&quot;true&quot;
        throwExceptions=&quot;false&quot;
        internalLogLevel=&quot;Off&quot; internalLogFile=&quot;c:\temp\nlog-internal.log&quot;&gt;
    &lt;targets&gt;
      &lt;target xsi:type=&quot;Console&quot;
              name=&quot;String&quot;
              layout=&quot;Layout&quot;
              footer=&quot;Layout&quot;
              header=&quot;Layout&quot;
              encoding=&quot;Encoding&quot;
      /&gt;
    &lt;/targets&gt;
  &lt;/nlog&gt;
  </code></pre>
  <p>Then in C#, the following two lines won't print to the console:</p>
  <pre><code>var logger = LogManager.GetCurrentClassLogger();
  logger.Info(&quot;hello&quot;);
  </code></pre>
  <p>Looked online but didn't find anything so far.</p>