[英]Is there an equivalent of System.Diagnostics.EventLog for C++?
I need to change the parameters of the Windows Event Log from a C++ code, and namely what is available via the System.Diagnostics.EventLog class in C#. 我需要从C ++代码更改Windows事件日志的参数,即通过C#中的System.Diagnostics.EventLog类提供的参数。 I need to read and later possibly modify the following properties:
我需要阅读,以后可能需要修改以下属性:
You can write the setting to the registry 您可以将设置写入注册表
MaximumKilobytes->MaxSize 最大千字节->最大大小
OverflowAction&MinimumRetentionDays->Retention 溢出操作和最小保留天数->保留
You can do that by getting and setting values in the registry. 您可以通过获取和设置注册表中的值来实现。 Microsoft has pretty detailed documentation on this one.
Microsoft在这一方面有非常详细的文档 。 You would be interested in
MaxSize
and Retention
values. 您将对
MaxSize
和Retention
值感兴趣。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.