Wait Method

Task Parallel System.Threading

Waits for the Task to complete execution.

Namespace:  System.Threading.Tasks
Assembly:  System.Threading (in System.Threading.dll)

Syntax

Visual Basic (Declaration)
Public Sub Wait
C#
public void Wait()

Exceptions

ExceptionCondition
System..::.AggregateException The Task was canceled -or- an exception was thrown during the execution of the Task.
System..::.ObjectDisposedException The Task has been disposed.

See Also