Some content on this site is available only to logged-in subscribers. Contact Us for information on becoming a subscriber.

InSource.Solutions | InSource Training | InSource Client Portal
InSource Solutions Logo
Log In Sign Up
InSource.Solutions InSource Training InSource Client Portal Log In Sign Up
  • Home
  • AVEVA Plant SCADA
  • AVEVA Plant SCADA Tech Notes

TN 1215 How to Retrieve Tag Information at Runtime

Last updated: March 6th, 2025

Description

  • Author: Benjamin Davis
  • Published: March 6th, 2025

Details:

Description

This article from InSource shows How to Retrieve Tag Information at Runtime

  • Author: Benjamin Davis
  • Published: 12/30/2021
  • Applies to: Citect

Details

Use the TagInfoEx function built into Citect.

  1. Create a tag.
  2. In Graphics Builder, enter TaginfoEx("TestTag", 1) as the display value.
  3. The tag information will show at runtime.

Here is a list of properties you can retreive...

The type of information to get:

0 - The Tag name from the variables table. This is the same as the Name argument. (Returned to be compatible with the AssInfo() function).

1 - Engineering units

2 - Raw zero scale

3 - Raw full scale

4 - Engineering zero scale

5 - Engineering full scale

6 - Width of the format

7 - Number of decimal places of format

8 - The Tag format as a long integer. The format information is stored in the integer as follows:

  • Bits 0-7 - format width
  • Bits 8-15 - number of decimal places
  • Bits 16 - zero-padded
  • Bit 17- left-justified
  • Bit 18 - display engineering units
  • Bit 20 - exponential (scientific) notation

9 - Logical Unit Number - I/O device number (for internal use)

10 - General Type - Protocol's general data type number for this tag. Type numbers are:

  • 0 - Digital
  • 1 - Byte
  • 2 - Integer16
  • 3 - UInteger16
  • 4 - Long
  • 5 - Real
  • 6 - String
  • 7 - ULong
  • 8 - Undefined

11 - Bit Width - Tag's size in bits. For example, an INT is 16 bits

Note: Types 12 to 15 are only supported when iCachedMode equals to 2 or 3.

12 - Unit Type - Protocol's unit type number for this tag

13 - Unit Address - Tag's address after the protocol DBF's template is applied.

14 - Unit Count - Array size. For example, if the tag's address is I1[50], the unit count is 50.

15 - Record Number - Tag's record number in variable.DBF - 1. That is, the first tag has a record number of 0.

16 - Comment - As defined in the variable tags list.

17 - ClusterName of the tag.

18 - Full name (cluster.tagname) of the tag.

19 - Reserved for internal operation.

20 - Configured Address of the tag. If the tag is not resolved, returns an empty string.

21 - Network Number - I/O device number (as defined by the Number field of the I/O Devices dialog).

22 - Name of the equipment associated with the Tag. If the tag is not resolved, returns an empty string.

If the tag is a local variable, mode 9 error code 348 is retrieved when cache mode is 0,1,2,3. Modes 12, 13, 14 and 15 will return an empty string (error 274 is trapped).

23 - Reserved for internal use.

24 - Reserved for internal use.

25 - Name of the equipment item associated with the Tag. If the tag is not resolved, returns an empty string.

26 - Custom 1 - a user-defined string.

27 - Custom 2 - a user-defined string.

28 - Custom 3 - a user-defined string.

29 - Custom 4 - a user-defined string.

30 - Custom 5 - a user-defined string.

31 - Custom 6 - a user-defined string.

32 - Custom 7 - a user-defined string.

33 - Custom 8 - a user-defined string.

tag information runtime retrieval
Give feedback about this article

Recommended articles

TN 1393 Deleting Tags from AVEVA Insight

Read More

How to receive group emails

Read More
Support Icon

CONTACT SUPPORT

How to reach us

10800 Midlothian Turnpike Tpke, Suite 209, Richmond, VA 23235

1.877.INSOURCE

Technical Support - 1.888.691.3858

Contact Us

  • InSource Solutions
  • InSource Training
  • InSource Client Portal
  • Log In
InSource Solutions Logo

© 2025 InSource Solutions. All Rights Reserved.

Knowledge Base Software powered by Helpjuice

Expand