RollingFileAppenderPreserveLogFileNameExtension Property Apache log4net™ SDK Documentation
Gets or sets a value indicating whether to preserve the file name extension when rolling.

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

public bool PreserveLogFileNameExtension { get; set; }

Property Value

Type: Boolean
true if the file name extension should be preserved.

By default file.log is rolled to file.log.yyyy-MM-dd or file.log.curSizeRollBackup. However, under Windows the new file name will loose any program associations as the extension is changed. Optionally file.log can be renamed to file.yyyy-MM-dd.log or file.curSizeRollBackup.log to maintain any program associations.

See Also