当我在nlog配置中使用它时:
<attribute name="Exception" encode="false" layout="${exception:format=@}"/>
json字符串包含“ \ r \ n”。如何用“ \ n”代替?
非常感谢!Gunnar
您是否尝试过使用此功能:
${replace:searchFor=\\\\r\\\\n:replaceWith=\\\\n:inner=${exception:format=@}}
另请参见:https://github.com/nlog/NLog/wiki/Replace-Layout-Renderer