共用方式為


JoinableTaskFactory.WaitSynchronously Method

Synchronously blocks the calling thread for the completion of the specified task. If running on the main thread, any applicable message pump is suppressed while the thread sleeps.

Namespace:  Microsoft.VisualStudio.Threading
Assembly:  Microsoft.VisualStudio.Threading (in Microsoft.VisualStudio.Threading.dll)

Syntax

'Declaration
Protected Friend Overridable Sub WaitSynchronously ( _
    task As Task _
)
protected internal virtual void WaitSynchronously(
    Task task
)
protected public:
virtual void WaitSynchronously(
    Task^ task
)
abstract WaitSynchronously : 
        task:Task -> unit  
override WaitSynchronously : 
        task:Task -> unit
function WaitSynchronously(
    task : Task
)

Parameters

.NET Framework Security

See Also

Reference

JoinableTaskFactory Class

Microsoft.VisualStudio.Threading Namespace