EventLogSession.ExportLog 方法    
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
将事件导出到外部日志文件中。 存储事件,不存储事件消息。
重载
| ExportLog(String, PathType, String, String) | 
						 将事件导出到外部日志文件中。 存储事件,不存储事件消息。  | 
        	
| ExportLog(String, PathType, String, String, Boolean) | 
						 将事件导出到外部日志文件中。 可以设置标记来指示即使对某些日志的指定查询失败此方法仍将继续导出事件。 存储事件,不存储事件消息。  | 
        	
ExportLog(String, PathType, String, String)
- Source:
 - EventLogSession.cs
 
- Source:
 - EventLogSession.cs
 
- Source:
 - EventLogSession.cs
 
将事件导出到外部日志文件中。 存储事件,不存储事件消息。
public:
 void ExportLog(System::String ^ path, System::Diagnostics::Eventing::Reader::PathType pathType, System::String ^ query, System::String ^ targetFilePath);
	public void ExportLog (string path, System.Diagnostics.Eventing.Reader.PathType pathType, string query, string targetFilePath);
	member this.ExportLog : string * System.Diagnostics.Eventing.Reader.PathType * string * string -> unit
	Public Sub ExportLog (path As String, pathType As PathType, query As String, targetFilePath As String)
	参数
- path
 - String
 
要从其中导出事件的事件日志名称,或要从其中导出事件的事件日志文件的路径。
- pathType
 - PathType
 
指定路径参数中使用的字符串是否指定事件日志的名称或事件日志文件的路径。
- query
 - String
 
用于选择要导出的事件的查询。 将仅导出从查询返回的事件。
- targetFilePath
 - String
 
执行此方法后存储导出事件的日志文件(以 .evtx 结尾)的路径。
另请参阅
适用于
ExportLog(String, PathType, String, String, Boolean)
- Source:
 - EventLogSession.cs
 
- Source:
 - EventLogSession.cs
 
- Source:
 - EventLogSession.cs
 
将事件导出到外部日志文件中。 可以设置标记来指示即使对某些日志的指定查询失败此方法仍将继续导出事件。 存储事件,不存储事件消息。
public:
 void ExportLog(System::String ^ path, System::Diagnostics::Eventing::Reader::PathType pathType, System::String ^ query, System::String ^ targetFilePath, bool tolerateQueryErrors);
	public void ExportLog (string path, System.Diagnostics.Eventing.Reader.PathType pathType, string query, string targetFilePath, bool tolerateQueryErrors);
	member this.ExportLog : string * System.Diagnostics.Eventing.Reader.PathType * string * string * bool -> unit
	Public Sub ExportLog (path As String, pathType As PathType, query As String, targetFilePath As String, tolerateQueryErrors As Boolean)
	参数
- path
 - String
 
要从其中导出事件的事件日志名称,或要从其中导出事件的事件日志文件的路径。
- pathType
 - PathType
 
指定路径参数中使用的字符串是否指定事件日志的名称或事件日志文件的路径。
- query
 - String
 
用于选择要导出的事件的查询。 将仅导出从查询返回的事件。
- targetFilePath
 - String
 
执行此方法后存储导出事件的日志文件(以 .evtx 结尾)的路径。
- tolerateQueryErrors
 - Boolean
 
              true 指示即使对某些日志的指定查询失败此方法仍将继续导出事件,false 指示指定查询失败时此方法将不再继续导出事件。