I have some toggles defined using an array:
DEFINE VARIABLE tog-Add AS LOGICAL EXTENT 12 INITIAL NO
VIEW-AS TOGGLE-BOX SIZE 6.86 BY .83 NO-UNDO.
I would like to enable or disable a specific toggle within the array using a variable.
I can do the following and it works fine:
ENABLE tog-ADD[1] WITH FRAME fra-List.
But if I try this I get an error:
ENABLE tog-ADD[v-num] WITH FRAME fra-List
This is the error:
Invalid use of variable subscript on non-fill-in widget. (3491)
Is there any way to do what I'm trying to do? I could do a CASE statement and create 12 assignments but then if the extent is changed, other code will need to be changed as well. I would like to know if it can be done with a single assignment using a variable in some way.
Thanks.
DEFINE VARIABLE tog-Add AS LOGICAL EXTENT 12 INITIAL NO
VIEW-AS TOGGLE-BOX SIZE 6.86 BY .83 NO-UNDO.
I would like to enable or disable a specific toggle within the array using a variable.
I can do the following and it works fine:
ENABLE tog-ADD[1] WITH FRAME fra-List.
But if I try this I get an error:
ENABLE tog-ADD[v-num] WITH FRAME fra-List
This is the error:
Invalid use of variable subscript on non-fill-in widget. (3491)
Is there any way to do what I'm trying to do? I could do a CASE statement and create 12 assignments but then if the extent is changed, other code will need to be changed as well. I would like to know if it can be done with a single assignment using a variable in some way.
Thanks.