Gets / Sets data type for PLC register values
One of the Tag.ATOMIC enumerations
Setting this property will also set the NetType property as follows:
| System.Boolean = ATOMIC.BOOL |
| System.SByte = ATOMIC.BYTE |
| System.Byte = ATOMIC.UBYTE |
| System.Int16 = ATOMIC.INT |
| System.UInt16 = ATOMIC.WORD |
| System.Int32 = ATOMIC.DINT |
| System.UInt32 = ATOMIC.DWORD |
| System.Single = ATOMIC.REAL |
| System.Double = ATOMIC.LREAL |
| System.String = ATOMIC.STRING |
| Exception Type | Condition |
|---|---|
| ArgumentException | Thrown if invalid DataType |
VB
Dim MyTag As New GELink.Tag("%R1")
' * set default type to DINT
MyTag.DataType = Tag.ATOMIC.DINT
C#
GELink.Tag MyTag = new GELink.Tag("%R1");
MyTag.DataType = Tag.ATOMIC.DINT;