Tag Element (Data)
The "tag" Element
When you wish to assign a tag to a component or thing, you will utilize a "tag" element. The complete list of attributes for this element is below.
group Id – Specifies the unique id of the tag group to which the tag being assigned belongs. tag Id – Specifies the unique id of the tag that must be assigned. name (Optional) Text – Specifies the name to be used for the tag. If empty, the unique id, as a text string, is used as the tag's name. Maximum length is 100 characters. Default: Empty. abbrev (Optional) Text – Specifies the abbreviation to be used for the tag. If empty, the name is used as the abbreviation, subject to any necessary truncation. Maximum length is 100 characters. Default: Empty.
IMPORTANT! If the tag group is dynamic, you can define new tags by simply assigning them to a component or a thing. When that occurs, you should always specify an appropriate name and abbreviation for the tag. The compiler defines new tags as they are encountered, so there is no way to ensure that one use of a new tag occurs before another, except for the basic rules governing the order in which data files with different file extensions are loaded.
The following example demonstrates what a "tag" element might look like. All default values are assumed for optional attributes.
<tag group="MyGroup" tag="MyTag" name="Tag Name" abbrev="Abbrev"/>