Share via


IDocumentService.CloseDocumentAsync Method

Definition

Closes the document identified by moniker.

public System.Threading.Tasks.Task CloseDocumentAsync (Uri moniker, Microsoft.VisualStudio.RpcContracts.Documents.SaveDocumentOption option, System.Threading.CancellationToken token);
abstract member CloseDocumentAsync : Uri * Microsoft.VisualStudio.RpcContracts.Documents.SaveDocumentOption * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function CloseDocumentAsync (moniker As Uri, option As SaveDocumentOption, token As CancellationToken) As Task

Parameters

moniker
Uri

The moniker of the document to close.

option
SaveDocumentOption

An option controlling if and how the document will be saved, if it has unsaved changes.

token
CancellationToken

The cancellation token.

Returns

A Task representing the asynchronous operation.

Remarks

Introduced in version DocumentService.

Applies to