From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

how to pass string to Excel_RangeSetItem

Excel_RangeSetItem is accepting only characters but i want to pass string values to it is there any way i traid ExcelRpt_WriteData(); but in this cell values are not moving forward this feature is there in Excel_RangeSetItem but this is not accepting strings, please suggest solution for this.

 

Thanks & Regards

0 Kudos
Message 1 of 2
(2,863 Views)

Excel_RangeSetItem accepts variants as arguments; in order to pass a CVI string to the function, you must format it in a variant with CAVT_CSTRING data type: this can be accomplished by using CA_VariantSetCString () function. For your reference, here is the list of data types that you can use in variant variables and the corresponding CVI types.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 2 of 2
(2,856 Views)