XmlLayoutBaseLocationInfo Property Apache log4net™ SDK Documentation
Gets a value indicating whether to include location information in the XML events.

Namespace: log4net.Layout
Assembly: log4net (in log4net.dll) Version: 4.0

public bool LocationInfo { get; set; }

Property Value

Type: Boolean
true if location information should be included in the XML events; otherwise, false.

If LocationInfo is set to true, then the file name and line number of the statement at the origin of the log statement will be output.

If you are embedding this layout within an SMTPAppender then make sure to set the LocationInfo option of that appender as well.

See Also