LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

setctrlmenuattribute

Solved!
Go to solution

Bonjour Smiley Happy,

j'utilise la fonction SetCtrlMenuAttribute pour mettre un item de mon menubar checked

Spoiler
void CVICALLBACK CB_Administrateur (int menuBar, int menuItem, void *callbackData,int panel) {     SetCtrlMenuAttribute (panel, menuBar,  menuItem, ATTR_CHECKED, 1);   }

ça m'affiche un message d'erreur: je comprends pas le source ou comment le résoudre

Spoiler

NON-FATAL RUN-TIME ERROR:   "SFT015AET.c", line 546, col 1, thread id 0x00001064:   Library function error (return value == -139 [0xffffff75]). Controls of the type passed do not have a menu

0 Kudos
Message 1 of 4
(2,826 Views)
Solution
Accepted by FibiIA

Hello, I'll answer in English...

 

SetCtrlMenuAttribute is destined to manipulate menus owned by particular controls like tables or others. To manipulate menu bars you must use SetMenuBarAttribute instead.



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 4
(2,823 Views)

Hi,

 

SetCtrlMenuAttribute is for control menus - not for menu bars... here you should use SetMenuBarAttribute Smiley Wink

0 Kudos
Message 3 of 4
(2,822 Views)

hi,

sorry for talking in frensh.

Thank you, that's what i ware searching for.

 

0 Kudos
Message 4 of 4
(2,817 Views)