INGEAR.NET.MBLINK

 

Tag.DataType Property

Gets / Sets data type for MODBUS device register values

[Visual Basic]
Public Property DataType As ATOMIC
[C#]
public Tag.ATOMIC DataType {get; set;}

Property Value

One of the Tag.ATOMIC enumerations

Remarks

Setting this property will also set the NetType property as follows:

Exceptions

Exception Type Condition
ArgumentException Thrown if invalid DataType

Example

VB
Imports MBLink
Dim MyTag As New Tag("40001")
' * set default type to DINT
MyTag.DataType = Tag.ATOMIC.DINT
C#
using MBLink;
Tag MyTag = new Tag("40001");
MyTag.DataType = Tag.ATOMIC.DINT;

See Also

Tag Class | MBLink Namespace