Dispatcher.InvokeAsync<TResult> Method (Func<TResult>, DispatcherPriority, CancellationToken)
Assembly: WindowsBase (in WindowsBase.dll)
public DispatcherOperation<TResult> InvokeAsync<TResult>( Func<TResult> callback, DispatcherPriority priority, CancellationToken cancellationToken )
A delegate to invoke through the dispatcher.
The priority that determines in what order the specified callback is invoked relative to the other pending operations in the Dispatcher.
An object that indicates whether to cancel the operation.
Return ValueType: System.Windows.Threading.DispatcherOperation< >
An object, which is returned immediately afteris called, that can be used to interact with the delegate as it is pending execution in the event queue.
The return value type of the specified delegate.
Available since 4.5