Compartir a través de


LanguageService.OpenDocument(String) Method

Definition

Opens the specified file.

public:
 void OpenDocument(System::String ^ path);
public:
 void OpenDocument(Platform::String ^ path);
void OpenDocument(std::wstring const & path);
public void OpenDocument (string path);
member this.OpenDocument : string -> unit
Public Sub OpenDocument (path As String)

Parameters

path
String

[in] The specified file to open.

Remarks

A language service typically does not need to open a source file so this method is seldom used. However, you can call this method to open a source file if your language service requires that functionality. Visual Studio normally loads a source file then instantiates your language service as needed.

The base method loads the specified source file using the current project.

Applies to