Smart TagRecognizer Object

The object that is responsible for recognizing a particular type of data as a smart tag is called a smart tag recognizer. These recognizers take the form of code in a Dynamic Link Library (DLL) that is loaded into Excel's address space when Excel is first loaded. To illustrate, on my system, the following code:

Dim str As SmartTagRecognizer

For Each str In Application.SmartTagRecognizers

Debug.Print str.progID & "/" & str.Enabled Next produces the output:

FName.SmartTag/True MOFL.SmartTag/True indicating that two smart tag recognizer DLLs are loaded in Excel's address space. (A single DLL may be used to recognize more than one type of smart tag.) We also see from this code that the SmartTagRecognizers collection holds a SmartTagRecognizer object for each of the currently available smart tag recognizers.

The SmartTagRecognizer object has a read-write Enabled property used to enable or disable the recognizer, as well as read-only properties called progID and FullName, which return the name of the recognizer (the FullName property includes the path).

0 0

Post a comment