LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

label hexa dans table

bjr

 

J'ai une table ( 2048 lignes et 16 colonnes) , c'est pour programmer une eeprom.

Je voudrais nommer le label de  chaque ligne  (row) par le debut de l'adresse hexa.

0000  sur la ligne 1

0010                     2

0020                     3

.......

........

7FFF    sur la ligne    2048

 Comment peut on faire avec je suppose la commande SetTableRowAttribute(panel, table, i , ATTR_LABEL_TEXT, label)

merci pour votre aide

riri

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

To set the row labels, you must for the first thing enable the row label attribute for the whole table, next iterate on all rows and set the row label. As an example, you could do the following:

 

// Set attribute for the whole table

SetTableRowAttribute (panel, control, -1, ATTR_USE_LABEL_TEXT, 1);


// Set lable for each row

for (idx = 1, r = 0; r < 100; r += 16) {

  sprintf (lbl, "%04X", r);
  SetTableRowAttribute (tmpH, Parm_ang, idx, ATTR_LABEL_TEXT, lbl);

  idx++;

}

 



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,931 Views)