LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

SetTableCellRangeVals - How do I declare Array of Arrays to pass in Strings

 

I'm using the SetTableCellRangeVals function.  I have a structure containing strings.  I'm populating an array of strings (array of array of characters) to get the strings from the structure into an array to use in SetTableCellRangeVals.  I have declared the array char strings[NumStr][StrLength].  I can populate this array in a for loop.

 

When I call SetTableCellRangeVals with "strings" as my parameter, I get  "found 'pointer to array 32 of char', expected 'pointer to pointer to char'. 

When I call SetTableCellRangeVals with "*strings" as my parameter, I get  "found 'pointer to char', expected 'pointer to pointer to char'.

When I call SetTableCellRangeVals with "strings[0]" as my parameter, I get  "found 'pointer to char', expected 'pointer to pointer to char'. 

 

How do I declare "strings" if I want to populate it in the for loop and use it in SetTableCellRangeVals?

 

(Windows 7 CVI 2010 SP1)

 

Thanks

0 Kudos
Message 1 of 5
(3,745 Views)

Hi,

take a look at LuisG answer here.



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 5
(3,740 Views)

If it helps anyone else, the part I didn't understand was that I needed an array of strings to hold the strings and an array of addresses to hold the address of each string within the array of strings.  Thanks.

0 Kudos
Message 3 of 5
(3,732 Views)

Hi, Hawkk.  Can you please post your code that uses the SetTableCellRangeVals() function and the declaration of the arrays that are passed to it?

0 Kudos
Message 4 of 5
(3,260 Views)

Sorry I looked but no longer have that SW.

0 Kudos
Message 5 of 5
(3,257 Views)