I need source code line number to the log entry through NLog.
Please let me know alternate ways to do it.
<<Log entry>> Line 23
<<Log entry>> Line 391
P.S. - 23, 391 are the source code line numbers. Thanks
You may use ${callsite:fileName=true} layout renderer - indicates whether to render the source file name and line number. Documentation.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With