共用方式為


TextDocument.TryGetText(SourceText) 方法

定義

如果檔已經載入且可用,請取得檔的目前文字。

public:
 bool TryGetText([Runtime::InteropServices::Out] Microsoft::CodeAnalysis::Text::SourceText ^ % text);
public bool TryGetText (out Microsoft.CodeAnalysis.Text.SourceText text);
public bool TryGetText (out Microsoft.CodeAnalysis.Text.SourceText? text);
member this.TryGetText : SourceText -> bool
Public Function TryGetText (ByRef text As SourceText) As Boolean

參數

text
SourceText

傳回

適用於