Quantcast
Channel: Measurement Studio for VC++ topics
Viewing all articles
Browse latest Browse all 653

How to read TDMS file use DDC_GetDat​aValuesStr​ing in C language.

$
0
0

1. Below code is correct, because the numDataValues is one, machine=sibot

char ss[10]={0};
    char *strMachine=new char[1];
    *strMachine=ss[10];
    nullChk (strMachine = (char *) malloc (sizeof (char) * (unsigned int)numDataValues));
    ddcChk (DDC_GetDataValuesString (channels[i], 0, (unsigned int)numDataValues, &strMachine));
    printf ("Channel value for Machine : %s\n", strMachine);

---then show "nel value for Machine : sibot"

 

2. But when the numDataValues is more one, I can't get all the data in the TDMS file, only can get the first one.

eg:

data one is FI,

data two is O

but I only can get FI....

what's wrong?? How to solve it?? The data format as attachment.


Viewing all articles
Browse latest Browse all 653


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>