08-03-2021 03:18 PM
I am trying to put a test that runs after clicking start test on the panel:
I ve already written a code that starts the test after clicking on the "Start test" button:
Is there any function that I can use to check if the elements in the panel are all full and not empty? Thanks a lot in advance.
if(event == EVENT_LEFT_CLICK)
{
switch(control)
{
case P_MAIN_Start_test:
if ( P_MAIN_Operator != 0 && P_MAIN_ARTICLE != 0 && P_MAIN_ORDER != 0)
{
iTimer_Handle = NewAsyncTimer (0.2, -1, 1, CALLBACK_MAIN_Start_test, 0);
}
}
}
08-03-2021 04:31 PM
You cannot operate this way: a contro ID (like e.g. P_MAIN_Operator) will never be 0!
You must retrieve the correct attribute (either the value or the index) for each control and check its validity accordingly. CVI offers a range checking facility and ValidatePanel () function that checks all controls in a panel that has Range Checking parameter in Notify mode, but it works only for numeric controls.
08-03-2021 04:35 PM - edited 08-03-2021 04:38 PM
And please try to not
08-04-2021 12:51 AM
I wanted to edit the questions I added but I found out it is not possible. I just reported them to the moderator to delete them.
Thanks a lot for the help 🙂