At the start of your program, create a control reference for each of the
controls that you want to disable in a single go. Build all the references
into an array and then pass the array into a 'for loop' which has a property
node within it that sets the disabled/enabled state. If you then select only
the 'for loop' and convert it into a subVI, you can use this anywhere in
your program to easily disable/enable the controls. All you need to wire
into the subVI when you call it, is a local variable connected to the array
of control references you created, and a constant that sets the value of the
property node inside the subVI.
This gives you a handy way to do what you want, you can also build arrays of
different controls, so that you can disable or enable groups of bu
ttons.
The best way yet is to put all your controls into a cluster, then create a
property node for the cluster. One of the properties of the cluster is the
'Controls[]' property which is effectively the same thing as the array I
mentioned before. but without you having to create loads of control
references manually!
Regards,
Dave.
"terp" wrote in message
news:50650000000800000015010100-1079395200000@exchange.ni.com...
> In a lot of occassions of my program, I need to disable more than 20
> controls and enable them later. Is there a way to disable/enable them
> in a shot so that I won't need to do that one by one? How about
> locking out the whole front panel?