10-20-2022 08:47 AM
Hello:
I am implementing a configuration menu with CVI, which allows placing several COMMANDBUTTON in a DIMMED position, I can do this, but if I close and open the program, the position of the COMMANDBUTTON returns to the initial condition, depending on what is set in the Control Setting in Panel.
Is it possible to modify the Dimmed condition in the Control Settings from the execution of the application?
Cheers
Carlos
10-20-2022 09:34 AM
I am not sure if I understood you correctly, but you can change whether a control is enabled or dimmed using the function SetCtrlAttribute ( panel_handle, control_id, ATTR_DIMMED, 1 ) for a disabled, dimmed control (and 0 for enabling it)
Hope it helps
10-20-2022 10:30 AM
Maybe see SavepanelState() / RecallPanelState() ?
10-20-2022 12:18 PM
Hello Wolfgang, thank you very much for your answer, but the use of SetCtrlAttribute, I already have it implemented, what I need is to be able to permanently store the changes made in the COMMANDBUTTON.
Cheers
Carlos
10-20-2022 12:24 PM
Hello Gdargaud, thank you very much for your answer, your proposal to use the SavepanelState() / RecallPanelState() functions is very interesting. I didn't know them.
After reading the help of these functions, I have the great doubt as I list all the COMMANDBUTTON of the Panel and its DIMMED condition. Do you have an example of how to use these functions?
int SavePanelState (int panelHandle, char filename[], int stateIndex);
Charles