IAsyncPersistFileFormat.LoadAsync Method

Definition

Opens a specified file asynchronously and initializes an object from the file contents.

public Microsoft.VisualStudio.Shell.Interop.IVsTask LoadAsync (string filename, uint grfMode, bool readOnly, Microsoft.VisualStudio.Shell.Interop.IVsProgress? progress);
abstract member LoadAsync : string * uint32 * bool * Microsoft.VisualStudio.Shell.Interop.IVsProgress -> Microsoft.VisualStudio.Shell.Interop.IVsTask
Public Function LoadAsync (filename As String, grfMode As UInteger, readOnly As Boolean, progress As IVsProgress) As IVsTask

Parameters

filename
String

The name of the file to load.

grfMode
UInt32

File format mode. If zero, the object uses the usual defaults as if the user had opened the file.

readOnly
Boolean

A value of true indicates that the file should be opened as read-only.

progress
IVsProgress

The interface through which progress is reported.

Returns

A task representing the asynchronous operation.

Remarks

This method is safe to access from any thread.

Applies to