NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

The Tutorial (Calling a Function with a Struct Parameter by CVI )does not work

I try to run the "tutorial of Calling a Function with a Struct Parameter by CVI" ,but it does not work.

Even I try the solution folder.

 

When debug the PassStructTest function, it does execute.

After execute, the local struct value in the sequence file keep no change, do not know why.

 

cvi code like below:

struct CVITutorialStruct {
    double measurement;
    char buffer[256];
};

//////////////////////////////////////////
__declspec(dllexport) void PassStructTest(struct CVITutorialStruct *cviStruct)
{
 
 if (cviStruct)
    {
      cviStruct->measurement = 10.0;
      strcpy(cviStruct->buffer, "Average Voltage");
     }
 
 //Insert function body here.
}

0 Kudos
Message 1 of 1
(1,884 Views)