//simple code String [] veParams=new String [4]. VeParams [0]="D: \ \ vestore \ "; VeParams [1]="C: \ \ Windows \ \ SysWOW64 \ "; VeParams [2]=""; VeParams [3]=""; InitConnect (veParams, 1000000); InsertData_struct dt=new InsertData_struct (); Dt. Type=0; Dt. Status=1; Dt. Time=1607435725; Dt. Value=https://bbs.csdn.net/topics/990.99; Dt. PointName="dcs01. TEST0000";; Int rs4=AppendRTTagDataByTagName (dt); Enclosing listBox1. Items. Add (" wrote: "+ rs4 +" - & gt; "+ dt. Value); //c + + struct Typedef struct InsertData_struct { The int type.//to zero for the switch quantity, 1 for analog quantity Int the status;//write some records the status of the A double value.//write some records the value of the Long time;//write some records of time, s Char pointName [RTDB_TAGNAME_LENGTH];//write some full name } InsertData;
//c # structure Public struct InsertData_struct { Public int type.//to zero for the switch quantity, 1 for analog quantity Public int the status;//write some records the status of the Public double value;//write some records the value of the Public long time;//write some records of time, s Public string pointName;//write some full name };
////////////////////////////////////////////////////////////////////// Anomalies appear the following error
CodePudding user response:
Int is int32, c # and c + + is int16, you need according to the relationship between c # and c + + type is modified, not only the int, char * c + + generally in c # to use StringBuilder instead. To search a type table under reference.