LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

write cstring to excel

Hello,
I want to write a cstring to an excel chart. Have had a look in the CVI sample codes for excel without being able to find anything. Anybody have a sample code for this?
best regards
Kurt
 
0 Kudos
Message 1 of 2
(3,213 Views)

After some testing, I found the answer by myself Smiley Very Happy:

 char myString[100]="test"
 error = CA_VariantSetCString(&myVariant, myString);
 

  error = Excel_RangeSetItem (hXl_Range, &ErrorInfo,
                CA_VariantInt (iRangeRow + 1), CA_VariantInt (iRangeCol + 1),
                myVariant));
Thanks

Kurt

0 Kudos
Message 2 of 2
(3,203 Views)