LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to handle a Large number of controls?

I Want to create an application wich will have to handle a lot of controls on it. I know how to get references of this controls, and how to acces them all programatically, but my problem is that there is just to many of them for Laview to run with no lag. It lags badly even on edit mode when I try to place all the controls I need. I think that ther must be a way to do this, since im going to have a lot of controls (look out in the image, I need 10 tabs of each grup with 5 subgrupsgrups on each tab, = 20tabs x 5subgrups x 40tags per subgrup x around 10 controls per tag = 40000 controls) but only a few of them are going to be showing in the front panel since most of them will be out of view. 

 

It's there any way I can handle this number of controls, considering I only need to visualize some of them at a given time ?? I have developed a sistem to expand, collapse, scroll up and down and stuff with the controls and it works fine with just a few tabs and subgrups but... I would prefere to stick up with this number of controls, to offer the capacity to expand the tags handled by the program while running, i could go down to a more situable number of controls like (16 tab control grups x 3 subgrups x 20 tags x 10 controls = 9600) wich is still a lot to be honest but I dont undersand why I cannot just have the controls lying on the fron panel doing nothing lags this much.

0 Kudos
Message 1 of 7
(3,799 Views)

A few possible approaches you may want to explore:

 

1. Use a table, multi-column listbox, or an array of clusters rather than 10 unique controls x 40 tags.

 

2. If the tabs are identical except for the group of tags they point at consider reusing the same controls and have the "tab switcher" simply swap out where the controls get their values from.

 

3. Use subpanels to recreate the behavior of the tab control. This means that tabs that aren't visible don't need to be in memory.

0 Kudos
Message 2 of 7
(3,763 Views)

I think that your second idea is rlly good, i willl have to work on how to do the swaping correctly and get the app to work  but this will alow me expand as much as i want. I must place the controls behaind the tab control with arrows so they show in every page ? or ther is another way for them to show in every tab with out this trick?

0 Kudos
Message 3 of 7
(3,745 Views)

Just to be clear, becous its ovious that I tryed to to something stupid, now I think this will do. I should create an array for every thing i want to control, and then simply make the tab control read the values of this array's when it swaps pages, to display them on the screen and also write to the array position wich is curently controling the value of the control ?

0 Kudos
Message 4 of 7
(3,742 Views)
You really need to avoid tab controls. Subpanels are better and cause fewer problems. A solution based on subpanels is also much more scalable -- which sounds like a major issue for you.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 5 of 7
(3,663 Views)

I recently wrote some articles about this very subject:

Monster Panel I

Monster Panel II

Monster Panel III

Monster Panel IV

Monster Panel V

 

I have almost 13000 controls/indicators on one VI panel (and four such windows in the program).

 

Perhaps there are some tips to help you.

 

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


Blog for (mostly LabVIEW) programmers: Tips And Tricks

Message 6 of 7
(3,622 Views)
Yes, exactly. Once you have started with a basic structure that assumes the application is built from separate bits, it gets much easier to scale or modify your application.

Need more tags? Not a problem, add additional screens (which ideally should be reentrant clones). Need fewer tags? Not a problem, remove screens. Feel a screen is getting too crowded? Not a problem, split it in 2 or 3.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 7 of 7
(3,613 Views)