10-10-2013 12:21 PM
Hello. Let me briefly outline what I am trying to do.
We have a board where motion sensors are mounted for testing. the wall is pre-wired with terminal strips to connect the units to, and a DAQ monitors the alarm outputs to see which ones alarm. I am developing the GUI to display the UUT#, information about the unit, and its alarm status. As not all the locations are used all the time, I will have a mechanism to configure which slots are monitored. The slots that are not being monitored I would like to indicate on the control panel those slots are not populated. The first item that comes to mind is to make the indicators (model number, reference, alarm) invisible, and leave the UUT# visible. the indicator consists of a 2 dimensional array that has a cluster embedded in it, and the cluster contains the uut#, model, reference, and alarm status. I can access one item in the cluster (working with Alarm) and when I make it visible/invisible it affects all elements in the array.
The next item I thought of would be to drop a tab inside the array, and one one tab put the indicators and leave the other one blank. When the index is not used, switch it to the blank one. That doesn't seem to work. Any suggestions?
Mike
10-10-2013 04:34 PM
Add a Boolean to your cluster. I like to use the Classic Flat Square Button.
Size it the same size or larger than your cluster in the the array and place it on top of all the other controls in the cluster.
Set one of Boolean states color to transparent (T) the other to gray.
Now just set the T/F state of the Boolean to enable or disable the slots as needed.
10-10-2013 04:59 PM
I can access one item in the cluster (working with Alarm) and when I make it visible/invisible it affects all elements in the array.
Yes. Only the value property can vary between elements in an array.
So, the Cluster.Alarm.visable property must apply to every element in the array of clusters. (You can't hide just some of them)
You will need a different data structure to do that.
10-10-2013 07:16 PM
As an added note: Move the UUT# to the "front" "Move To Front" (Ctrl+Shift+K) in front of the boolean so that the UUT# is still visiable when everything else is hidden behine the boolean.
10-11-2013 07:57 AM
Another way you can go is basically creating an "array" of subpanels, where each element can then be truly different. You can find examples of this in this thread and the thread it links to. This approach is more complex, but it allows for more freedom in the display.
10-11-2013 04:42 PM
10-14-2013 06:20 AM
I did figure it out. I went with a cluster data structure. I wanted to use an array for ease of updating the data. It was essential for the design to make the unused items either grayed out or not visible, I opted for not visible. Let me bring up my design to see how I implemented it.
It would be easier if I just attach the code I developed. The code may develop a little further, but it's a work in progress.