Sto implementando la registrazione nella mia app tramite NLog. Questo è il mio Nlog.Config:NLog non effettua l'accesso con ClickOnce
<?xml version="1.0" encoding="utf-8" ?>
<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<targets async="true">
<target xsi:type="File"
name="ExceptionTarget"
fileName="LOG.txt"
layout="${date:format=dd MMM yyyy HH-mm-ss} ${uppercase:${level}} ${newline}${message} ${exception::maxInnerExceptionLevel=5:format=ToString}${newline}${stacktrace}${newline}"/>
</targets>
<targets async="true">
<target xsi:type="File"
name="InfoTarget"
fileName="LOG.txt"
layout="${date:format=mm-ss} ${uppercase:${level}} ${newline}${message} ${newline}"/>
</targets>
<rules>
<logger name="*" level="Error" writeTo="ExceptionTarget"/>
<logger name="*" level="Info" writeTo="InfoTarget"/>
</rules>
</nlog>
Quando schiero l'applicazione con ClickOnce, viene creato alcun file log.txt. Non si verificano errori e la mia app funziona normalmente, ma non succede nulla.
Come risolvere questo problema?