ISmartTagExtension.Recognize(String, ISmartTagRecognizerSite, ISmartTagTokenList, SmartTagRecognizeContext) 方法

定義

在文件的文字中搜尋已辨識字詞。Searches text in the document for recognized terms. 此類型或成員僅適用於 2007 Microsoft Office 系統的專案。This type or member is intended to be used only in projects for the 2007 Microsoft Office system. 智慧標籤在 Office 2010 中已被取代。Smart tags are deprecated in Office 2010...

public void Recognize (string text, Microsoft.Office.Interop.SmartTag.ISmartTagRecognizerSite site, Microsoft.Office.Interop.SmartTag.ISmartTagTokenList tokenList, Microsoft.Office.Tools.Word.SmartTagRecognizeContext context);

參數

text
String

要搜尋已辨識字詞的文字。The text to search for recognized terms.

site
Microsoft.Office.Interop.SmartTag.ISmartTagRecognizerSite

活頁簿或文件中文字的位置。The location of the text in the workbook or document.

tokenList
Microsoft.Office.Interop.SmartTag.ISmartTagTokenList

要搜尋已辨識字詞的文字,細分為權杖清單。The text to search for recognized terms, broken down into a list of tokens.

context
SmartTagRecognizeContext

提供段落中傳送至辨識器之文字的物件,以及可呼叫以指出找到智慧標籤的方法。An object that provides the text from the paragraph that is sent to the recognizer and a method you can call to indicate that the smart tag was found.

備註

這個方法是由所呼叫 Visual Studio Tools for Office RuntimeVisual Studio Tools for Office runtime ,以搜尋文字中是否有辨識的字詞。This method is called by the Visual Studio Tools for Office RuntimeVisual Studio Tools for Office runtime to search text for recognized terms. 如果您想要加入自己的搜尋演算法,以便在標準辨識器以外執行,請執行此方法。Implement this method if you want to incorporate your own search algorithms to run in addition to the standard recognizers.

若要查看程式碼範例,請參閱本主題的 Microsoft Visual Studio 2008/.NET Framework 3.5 版本。To view a code example, see the Microsoft Visual Studio 2008/.NET Framework 3.5 version of this topic.

適用於