Applies To: |
|
Summary: |
TagRead() does not round the decimal
places of the return value as defined in the "Format" field of
the variable tag form. This used to work up to CitectSCADA version 6.0 but not in CitectSCADA version 7.0 and 7.1? |
Solution: |
You can use this workaround to accomplish the same functionality: Function: REAL FUNCTION TagReadFmt
(STRING stag)
REAL value = 0; INT fmt = 0; INT dec = 0; fmt = TagInfo(stag,8); dec = (fmt BITAND 0xff00) / 0xff; value = Round(TagRead(stag),dec); RETURN value;
END |
Keywords: |
TagRead, format |
Related Links
Attachments