|
696 | 696 |
|
697 | 697 | The example uses the following message text file, built into the resource library EventLogMsgs.dll. A message text file is the source from which the message resource file is created. The message text file defines the resource identifiers and text for the category, event message, and parameter insertion strings. Specifically, resource identifier 5001 is defined for the localized name of the event log.
|
698 | 698 |
|
699 |
| -``` |
| 699 | +```txt |
700 | 700 | ; // EventLogMsgs.mc
|
701 | 701 | ; // ********************************************************
|
702 | 702 |
|
@@ -2513,15 +2513,15 @@ SVC_UPDATE.EXE
|
2513 | 2513 | <summary>This property is deprecated.</summary>
|
2514 | 2514 | <value>To be added.</value>
|
2515 | 2515 | <remarks>
|
2516 |
| - <format type="text/markdown"><![CDATA[ |
2517 |
| - |
2518 |
| -## Remarks |
| 2516 | + <format type="text/markdown"><![CDATA[ |
| 2517 | +
|
| 2518 | +## Remarks |
2519 | 2519 |
|
2520 | 2520 | > [!IMPORTANT]
|
2521 | 2521 | > Support for the <xref:System.Diagnostics.EventLog.MinimumRetentionDays%2A> property was removed in Windows Vista and later operating systems. Setting this value can cause the Event Log to never overwrite events, and to drop all events to the channel once it is full.
|
2522 |
| - |
2523 |
| -## Examples |
2524 |
| - The following example enumerates the event logs defined on the local computer, and displays configuration details for each event log. |
| 2522 | +
|
| 2523 | +## Examples |
| 2524 | + The following example enumerates the event logs defined on the local computer, and displays configuration details for each event log. |
2525 | 2525 |
|
2526 | 2526 | :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/EventLogProperties/CPP/source.cpp" id="Snippet2":::
|
2527 | 2527 | :::code language="csharp" source="~/snippets/csharp/System.Diagnostics/EventLog/GetEventLogs/source1.cs" id="Snippet2":::
|
@@ -2587,11 +2587,11 @@ SVC_UPDATE.EXE
|
2587 | 2587 | The <xref:System.Diagnostics.EventLog.ModifyOverflowPolicy%2A> method configures the overflow behavior of an event log. <xref:System.Diagnostics.EventLog> instance. After calling this method for the event log specified by the <xref:System.Diagnostics.EventLog.Log%2A> property, the <xref:System.Diagnostics.EventLog.OverflowAction%2A> and <xref:System.Diagnostics.EventLog.MinimumRetentionDays%2A> property values reflect the newly configured overflow behavior.
|
2588 | 2588 |
|
2589 | 2589 | > [!NOTE]
|
2590 |
| -> This property represents a configuration setting for the event log represented by this instance. When the event log reaches its maximum size, this property specifies how the operating system handles new entries written by all event sources registered for the event log. |
2591 |
| - |
2592 |
| - Set the `action` parameter to <xref:System.Diagnostics.OverflowAction.OverwriteAsNeeded> to indicate that a new entry overwrites the oldest entry when the <xref:System.Diagnostics.EventLog> reaches its maximum size. If the `action` parameter is set to <xref:System.Diagnostics.OverflowAction.OverwriteAsNeeded>, the `retentionDays` parameter value is ignored. |
| 2590 | +> This property represents a configuration setting for the event log represented by this instance. When the event log reaches its maximum size, this property specifies how the operating system handles new entries written by all event sources registered for the event log. |
2593 | 2591 |
|
2594 |
| - Set the `action` parameter to <xref:System.Diagnostics.OverflowAction.DoNotOverwrite> to discard new events when the maximum log size is reached. If the `action` parameter is set to <xref:System.Diagnostics.OverflowAction.DoNotOverwrite>, the `retentionDays` parameter value is ignored. |
| 2592 | + Set the `action` parameter to <xref:System.Diagnostics.OverflowAction.OverwriteAsNeeded> to indicate that a new entry overwrites the oldest entry when the <xref:System.Diagnostics.EventLog> reaches its maximum size. If the `action` parameter is set to <xref:System.Diagnostics.OverflowAction.OverwriteAsNeeded>, the `retentionDays` parameter value is ignored. |
| 2593 | +
|
| 2594 | + Set the `action` parameter to <xref:System.Diagnostics.OverflowAction.DoNotOverwrite> to discard new events when the maximum log size is reached. If the `action` parameter is set to <xref:System.Diagnostics.OverflowAction.DoNotOverwrite>, the `retentionDays` parameter value is ignored. |
2595 | 2595 |
|
2596 | 2596 | > [!WARNING]
|
2597 | 2597 | > Never set the `action` parameter to <xref:System.Diagnostics.OverflowAction.OverwriteOlder>. This value is deprecated and might cause the log to behave as if the `DoNotOverwrite` parameter was passed instead.
|
@@ -2756,7 +2756,7 @@ SVC_UPDATE.EXE
|
2756 | 2756 |
|
2757 | 2757 | The example uses the following message text file, built into the resource library EventLogMsgs.dll. A message text file is the source from which the message resource file is created. The message text file defines the resource identifiers and text for the category, event message, and parameter insertion strings. Specifically, resource identifier 5001 is defined for the localized name of the event log.
|
2758 | 2758 |
|
2759 |
| -``` |
| 2759 | +```txt |
2760 | 2760 | ; // EventLogMsgs.mc
|
2761 | 2761 | ; // ********************************************************
|
2762 | 2762 |
|
@@ -4446,7 +4446,7 @@ SVC_UPDATE.EXE
|
4446 | 4446 |
|
4447 | 4447 | The example uses the following message text file, built into the resource library EventLogMsgs.dll. A message text file is the source from which the message resource file is created. The message text file defines the resource identifiers and text for the category, event message, and parameter insertion strings.
|
4448 | 4448 |
|
4449 |
| -``` |
| 4449 | +```txt |
4450 | 4450 | ; // EventLogMsgs.mc
|
4451 | 4451 | ; // ********************************************************
|
4452 | 4452 |
|
@@ -4679,7 +4679,7 @@ SVC_UPDATE.EXE
|
4679 | 4679 |
|
4680 | 4680 | The example uses the following message text file, built into the resource library EventLogMsgs.dll. A message text file is the source from which the message resource file is created. The message text file defines the resource identifiers and text for the category, event message, and parameter insertion strings.
|
4681 | 4681 |
|
4682 |
| -``` |
| 4682 | +```txt |
4683 | 4683 | ; // EventLogMsgs.mc
|
4684 | 4684 | ; // ********************************************************
|
4685 | 4685 |
|
@@ -4898,7 +4898,7 @@ SVC_UPDATE.EXE
|
4898 | 4898 |
|
4899 | 4899 | The example uses the following message text file, built into the resource library EventLogMsgs.dll. A message text file is the source from which the message resource file is created. The message text file defines the resource identifiers and text for the category, event message, and parameter insertion strings.
|
4900 | 4900 |
|
4901 |
| -``` |
| 4901 | +```txt |
4902 | 4902 | ; // EventLogMsgs.mc
|
4903 | 4903 | ; // ********************************************************
|
4904 | 4904 |
|
@@ -5117,7 +5117,7 @@ SVC_UPDATE.EXE
|
5117 | 5117 |
|
5118 | 5118 | The example uses the following message text file, built into the resource library EventLogMsgs.dll. A message text file is the source from which the message resource file is created. The message text file defines the resource identifiers and text for the category, event message, and parameter insertion strings.
|
5119 | 5119 |
|
5120 |
| -``` |
| 5120 | +```txt |
5121 | 5121 | ; // EventLogMsgs.mc
|
5122 | 5122 | ; // ********************************************************
|
5123 | 5123 |
|
|
0 commit comments