共用方式為


AsyncOperationProgressHandler<TResult,TProgress> 代理人

定義

表示處理非同步作業的進度更新事件,以提供進度更新的方法。

/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.FoundationContract, 65536)]
/// [Windows.Foundation.Metadata.Guid(1432946946, 2731, 16922, 135, 120, 248, 206, 80, 38, 215, 88)]
template <typename TResult, typename TProgress>
class AsyncOperationProgressHandler : MulticastDelegate
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.FoundationContract), 65536)]
[Windows.Foundation.Metadata.Guid(1432946946, 2731, 16922, 135, 120, 248, 206, 80, 38, 215, 88)]
public delegate void AsyncOperationProgressHandler<TResult,TProgress>(IAsyncOperationWithProgress<TResult,TProgress> asyncInfo, TProgress progressInfo);
Public Delegate Sub AsyncOperationProgressHandler(Of TResult, TProgress)(asyncInfo As IAsyncOperationWithProgress(Of TResult, TProgress), progressInfo As TProgress)

類型參數

TResult
TProgress

參數

asyncInfo
IAsyncOperationWithProgress<TResult,TProgress>

非同步作業。

progressInfo
TProgress

進度資訊。

屬性

Windows 需求

裝置系列
Windows 10 (已於 10.0.10240.0 引進)
API contract
Windows.Foundation.FoundationContract (已於 v1.0 引進)

範例

如需說明如何處理Progress事件的C++/WinRT程式碼範例,請參閱非同步動作和作業的委派類型

適用於