Creating Application-Level Smart Tags


VSTO's document-level Smart Tags are great when you want to recognize a term in a particular document or a class of document created from a template. What are your options when you want to recognize a term in all open documents?

You can control the text that Word or Excel recognizes at an application level and the actions made available for that text by creating a Smart Tag DLL. A Smart Tag DLL contains two types of classes that are used by Office: a recognizer class and an action class. A recognizer class tells Office the text in the workbook to recognize. The recognizer class "tags" recognized text by creating a property bageven an empty property bagand attaching it to recognized text. An action class corresponds to an action displayed in the pop-up menu that Office displays when a user hovers over a recognized piece of text. Recognizer classes implement the ISmartTagRecognizer interface and optionally the ISmartTagRecognizer2 interface. Action classes implement the ISmartTagAction interface and optionally the ISmartTagAction2 interface.




Visual Studio Tools for Office(c) Using Visual Basic 2005 with Excel, Word, Outlook, and InfoPath
Visual Studio Tools for Office: Using Visual Basic 2005 with Excel, Word, Outlook, and InfoPath
ISBN: 0321411757
EAN: 2147483647
Year: N/A
Pages: 221

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net