RichTextBox.GetSpellingError(TextPointer) 方法

定義

傳回與 RichTextBox 內容中指定位置的任何拼字錯誤相關聯的 SpellingError 物件。

public:
 System::Windows::Controls::SpellingError ^ GetSpellingError(System::Windows::Documents::TextPointer ^ position);
public System.Windows.Controls.SpellingError GetSpellingError (System.Windows.Documents.TextPointer position);
member this.GetSpellingError : System.Windows.Documents.TextPointer -> System.Windows.Controls.SpellingError
Public Function GetSpellingError (position As TextPointer) As SpellingError

參數

position
TextPointer

TextPointer,指定位置和邏輯方向,這些會解析為字元,以檢查拼字錯誤。 使用這個 TextPointerLogicalDirection 屬性以指定要檢查之字元的方向。

傳回

SpellingError

SpellingError 物件,其中包含 position 所指定的字元處所找到之拼字錯誤的詳細資料;如果指定的字元處沒有任何拼字錯誤,則為 null

備註

TextPointer 通常 position 指定兩個字元之間的位置。 使用 的 LogicalDirection position 屬性來指定要檢查的字元。

適用於

另請參閱