Search code examples
nlog

With NLog can I set the property of a LayoutRender using the value of another one?


I'd like to use a LayoutRenderer in the configuration of another one, for example something like

${message:exceptionSeparator=${newline}:withException=true}

is that possible?

thanks


Solution

  • Guess you can use this work-around:

    ${message}${onexception:${newline}}${exception:format=tostring}
    

    But yes it would be nice to support string-literal-tokens like ${newline} for standard string-properties.