I am new to using NLog and I am trying to implement a custom layout renderer that indents based on stack depth. Currently I am using the layout from here:
https://stackoverflow.com/questions/5951102/nlog-custom-layoutrenderer-for-scope-indentation
So like:
Method A calls:
Method D calls:
Method E end
I have put the code from that post inside of a class in my project and I placing this in my code before logging begins: LayoutRenderer.Register("IndentationLayout", typeof(IndentationLayoutRenderer));
That seems to be the way everyone is implementing it, but when I check the internal logs it seems to never even recognize the layout and just goes to default. Anyone have any ideas?
Thanks