LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Can I load all values into a table from another table?

I have a large LabWindows table that I need to update quite frequently. I am currently using SetTableCellAttribute to set the various fields into the Table. However, the table blinks and seems to freeze as I am going through a large number of SetTableCellAttributes. In order to avoid this blinking and freezing, I was wondering whether I can load up a second table (either a LabWindows Table or just a c++ table), and then when the second table is completely populated, then I can issue a LabWindows command to populate the entire table with one command. Does such a command exist? If not do you have any ideas?
Thnaks,
Donna
0 Kudos
Message 1 of 2
(2,978 Views)
Load your data into an array, then use SetTableCellRangeVals() to update the UIR table control with the data from the array. If all the data in the table needs to be updated, set the range to VAL_TABLE_ENTIRE_RANGE. If a subset of the table needs to be updated, define a rectangle big enough to hold the updated data.
SetTableCellRangeVals (panel, control, VAL_TABLE_ENTIRE_RANGE, yourArray, VAL_ROW_MAJOR);
Look at the online help for SetTableCellRangeVals().
Look at the sample program gridview.prj that ships with CVI. The GenDataToTable() function generates the data in an array, then writes it to the UIR table control.
0 Kudos
Message 2 of 2
(2,970 Views)