GetFieldName
Returns the name of the field the tag is assigned to.
Compatibility
Available as of IDEA version 12.0
Syntax
GetFieldName (tagId As String) As String
Parameters
tagId
Tag ID (case insensitive).
Return Value
Returns the name of the field (as string) to which the tag with the specified ID is assigned.
If the tag is not assigned to any field, an empty string is returned.
Remarks
The tag might be assigned to multiple fields. Method GetFieldName() returns only the first field name found. Therefore, this method should be used with care.
Example
Sub Main()
Dim ac As Object
Dim tagging As Object
Set ac = CreateObject("SmartAnalyzer.AutomationClient")
Set tagging = ac.GetTagging("Sample-Weblog")
fieldName = Tagging.GetFieldName("CustomerCode")
If Len(fieldName) = 0 THEN
MsgBox"No field is assigned to tag 'CustomerCode'"
ELSE
MsgBox "Field '" + fieldName + "' is assigned to tag 'CustomerCode'"
END IF
End Sub