FileLogTraceListener::ReserveDiskSpace Property
Gets or sets the amount of free disk space, in bytes, necessary before messages can be written to the log file.
Assembly: Microsoft.VisualBasic (in Microsoft.VisualBasic.dll)
public: property long long ReserveDiskSpace { long long get(); void set(long long value); }
Property Value
Type: System::Int64Long. This is the amount of free disk space necessary. The default value is 10000000.
| Exception | Condition |
|---|---|
| ArgumentException | When this property is set to a value less than 0. |
Use this property to make sure that the log files do not completely fill the disk.
If the amount of free disk space (in bytes) is less than the value of this property, then when the FileLogTraceListener class attempts to write a message to the log, the message is discarded and the failure is either silent or an exception is thrown depending on the value of the DiskSpaceExhaustedBehavior property. Otherwise, the message is written to the log, if the log file size (in bytes) is greater than MaxFileSize.
Available since 2.0