cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Need help navigating or using the PTC Community? Contact the community team. X

Kepware Configuration API Datatypes Conversion

JK_10744682
9-Granite

Kepware Configuration API Datatypes Conversion

Hi all,

 

I have been experimenting with the Kepware Configuration API, specifically creating tags.

 

I see that the data types in the API (EX: "servermain.TAG_DATA_TYPE": 21) are integer form, but I am unable to find a table that shows which data type converts to which integer, and when I create a tag without putting in a data type in the content it doesn't seem to automatically get the correct data type.

 

Anyone know what integers correlate to which data types? 

Thanks!

ACCEPTED SOLUTION

Accepted Solutions

Please see the reference code below:

 

*****************************

{
        "symbolic_name": "servermain.TAG_DATA_TYPE",
        "display_name": "Data Type",
        "display_description": "Select the format of the incoming tag data.",
        "read_only": false,
        "type": "Enumeration",
        "default_value": -1,
        "enumeration": {
            "Default": -1,
            "String": 0,
            "Boolean": 1,
            "Char": 2,
            "Byte": 3,
            "Short": 4,
            "Word": 5,
            "Long": 6,
            "DWord": 7,
            "Float": 8,
            "Double": 9,
            "BCD": 10,
            "LBCD": 11,
            "Date": 12,
            "LLong": 13,
            "QWord": 14,
            "String Array": 20,
            "Boolean Array": 21,
            "Char Array": 22,
            "Byte Array": 23,
            "Short Array": 24,
            "Word Array": 25,
            "Long Array": 26,
            "DWord Array": 27,
            "Float Array": 28,
            "Double Array": 29,
            "BCD Array": 30,
            "LBCD Array": 31,
            "Date Array": 32,
            "LLong Array": 33,
            "QWord Array": 34
        }

******************************

 

-Andy

Andy Servetas
Principal Technical Support Engineer | Kepware Technologies

View solution in original post

1 REPLY 1

Please see the reference code below:

 

*****************************

{
        "symbolic_name": "servermain.TAG_DATA_TYPE",
        "display_name": "Data Type",
        "display_description": "Select the format of the incoming tag data.",
        "read_only": false,
        "type": "Enumeration",
        "default_value": -1,
        "enumeration": {
            "Default": -1,
            "String": 0,
            "Boolean": 1,
            "Char": 2,
            "Byte": 3,
            "Short": 4,
            "Word": 5,
            "Long": 6,
            "DWord": 7,
            "Float": 8,
            "Double": 9,
            "BCD": 10,
            "LBCD": 11,
            "Date": 12,
            "LLong": 13,
            "QWord": 14,
            "String Array": 20,
            "Boolean Array": 21,
            "Char Array": 22,
            "Byte Array": 23,
            "Short Array": 24,
            "Word Array": 25,
            "Long Array": 26,
            "DWord Array": 27,
            "Float Array": 28,
            "Double Array": 29,
            "BCD Array": 30,
            "LBCD Array": 31,
            "Date Array": 32,
            "LLong Array": 33,
            "QWord Array": 34
        }

******************************

 

-Andy

Andy Servetas
Principal Technical Support Engineer | Kepware Technologies

Announcements


Top Tags