Smart Tags: Dumb Technology? (4/4) - exploring XML | WebReference

Smart Tags: Dumb Technology? (4/4) - exploring XML

Smart Tags: Dumb Technology?

Here's how to test this code sample:

Copy the above code to a text file named stockquote.xml and save it under C:\Program Files\Common Files\Microsoft Shared\Smart Tag\Lists. Quit all running instances of Office and Explorer to reset the smart tag engine. Start Word 2002, Excel 2002, or Outlook 2002, and in any existing or new Word document, Excel spreadsheet, or Word-enabled e-mail, type INTM or INTC, and then press ENTER. Hover your mouse pointer over INTM or INTC, click the Smart Tag Actions button, and then click "Stock Quote by Symbol."

The terms element includes a child element that takes one of two forms:

You might be wondering at this point why you can't just type INTM or INTC, and have it recognized as a smart tag, instead of typing out long lists of terms. Well, the computer doesn't see INTM as being any different from ABCDE or even 1A2B3C456XYZ. You have to provide a list of terms. That's not to say that you can't programmatically extract a list of ZIP codes from a database and insert them as a comma-delimited list of values in the termlist element. You can even get a little fancier with a smart tag DLL by providing a search pattern, like any string of characters ending in "lbs.". However, you must provide a fixed list of values in the termlist element (or the name of a specially-constructed .dat or .bin file that contains terms) in a smart tag XML file.

Developing a Smart Tag DLL is beyond the scope of this article, refer to the Microsoft Office XP Smart Tag SDK for all the Windows coding-specifics that might not be of general interest.

Conclusion

Smart Tags are a controversial topic these days. While providing linking information from outside the original document can be powerful, it can also be harmful if it isn't clear what is external to the document and what is not.

By using a text or HTML editor, you can make your Web pages smart-tag aware. Assuming your users have Office XP and the appropriate smart tag DLL or smart tag XML list description file installed on their computers, the Smart Tag Options button and associated actions will be available for properly-tagged terms on your Web pages.

That only excludes all the people that don't have Office XP and Internet Explorer 5 or later...

Produced by Michael Claßen

URL: https://www.webreference.com/xml/column38/4.html
Created: Aug 29, 2001
Revised: Aug 29, 2001