You can create custom smart tags for use in Microsoft Office XP by using Extensible Markup Language (XML). Smart tags created in this way are called Smart Tag Lists. These Smart Tag Lists can only recognize a static list of terms and make use of Web-based actions.
This article contains a sample of the XML code that is needed to create a Smart Tag List.
Microsoft provides programming examples for illustration only, without warranty either expressed or implied. This includes, but is not limited to, the implied warranties of merchantability or fitness for a particular purpose. This article assumes that you are familiar with the programming language that is being demonstrated and with the tools that are used to create and to debug procedures. Microsoft support engineers can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific requirements.
Sample XML Code to Create a Smart Tag List
<FL:name>MSN City Lookup</FL:name>
<FL:description>Looks up City Guides on MSN</FL:description>
<FL:caption>Lookup MSN City Guide</FL:caption>
To use the preceding code, follow these steps.NOTE
: Close all Microsoft Office XP programs first.
- Select all of the preceding code, and copy the selection.
- Open Notepad.
- Paste the code into a new Notepad file.
- On the File menu, select Save As.
- In the Save As dialog box, browse to the following folder:
C:\Program Files\Common Files\Microsoft Shared\Smart Tag\Lists
- Save the file in this folder as "CityGuide.XML"
NOTE The quotation marks around the file name are required to ensure that a .txt extension is not added to the file name.
- Start Microsoft Excel 2002 or Microsoft Word 2002.
- On the Tools menu, click AutoCorrect Options, and then click the Smart Tags tab.
- In Excel, verify that the Label data with smart tags check box is selected. In Word, verify that the Label text with smart tags check box is selected. In both programs, verify that the Smart tag lists check box is selected in the Recognizers List. Click OK to close the dialog box.
- In the open spreadsheet or document, type Seattle. Notice the smart tag indicator that appears.
- Click the Smart Tag button, and then select Lookup MSN City Guide.
Smart Tag Lists created with XML do not require you to compile a DLL. Instead, they use the Mofl.dll file that is included with Microsoft Office XP. This means that all Smart Tag Lists are turned on or off as a group in the Smart Tag Options
For more information about creating smart tags, refer to the Microsoft Smart Tag Software Developer's Kit at the following Microsoft Web site:
Article ID: 287698 - Last Review: January 12, 2015 - Revision: 7.0
- Microsoft Excel 2002 Standard Edition
- Microsoft Word 2002
|kbnosurvey kbarchive kbhowto KB287698|