使用为此方法指定的参数将中间文件异步发送至 DataCollectionSink。
命名空间:  Microsoft.VisualStudio.TestTools.Execution
程序集:  Microsoft.VisualStudio.QualityTools.ExecutionCommon(在 Microsoft.VisualStudio.QualityTools.ExecutionCommon.dll 中)
语法
声明
Public Sub SendFileAsync ( _
    context As DataCollectionContext, _
    path As String, _
    description As String, _
    deleteFile As Boolean _
)
public void SendFileAsync(
    DataCollectionContext context,
    string path,
    string description,
    bool deleteFile
)
public:
void SendFileAsync(
    DataCollectionContext^ context, 
    String^ path, 
    String^ description, 
    bool deleteFile
)
member SendFileAsync : 
        context:DataCollectionContext * 
        path:string * 
        description:string * 
        deleteFile:bool -> unit 
public function SendFileAsync(
    context : DataCollectionContext, 
    path : String, 
    description : String, 
    deleteFile : boolean
)
参数
- context
 类型:Microsoft.VisualStudio.TestTools.Execution.DataCollectionContext
 一个 IBaseRunContext,用于描述运行测试的上下文。不能为 nullnull 引用(在 Visual Basic 中为 Nothing)。
- path
 类型:System.String
 文件所在的本地路径。
- description
 类型:System.String
 文件的简短说明。
- deleteFile
 类型:System.Boolean
 true 表示在发送文件后自动将其删除;否则为 false。
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关更多信息,请参见通过部分受信任的代码使用库。