LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Nested Subpanels for LVOOP Class Hierarchy

Hi,

 

I am trying to figure out a way to create a configuration window for a class object using a subpanel. The problem is that I have LVOOP class hierarchy of 3 levels, and thus I want to use nested subpanels, one subpanel for each inheritance.

 

For example, 

 

A.lvclass (abstract class)

  • Private Data Members
    •  String A
  • Configuration Window VI ( Within a FP there is a String A control and a subpanel for its child class)

B.lvclass (abstract class) (child of A.lvclass)

  • Private Data Members
    • Boolean A
    • Boolean B
  • Configuration Window VI (Within the FP there is a Boolean A control and a Boolean B control, plus a subpanel for its child class)

C1.lvclass (concrete class) (child of B.lvclass)

  • Private Data Members
    • File Path A
  • Configuration Window VI (Within the FP there is a File Path A control)

C2.lvclass (concrete class) (child of B.lvclass)

  • Private Data Members
    • Boolean C
  • Configuration Window VI (Within the FP there is a Boolean C control)

 

What I am trying to accomplish is to create configuration windows for C1 and C2. For each configration window, there are sections for class A and class B, and for the class itself. However, I do not want to recreate the same section (for A and B) over and over again each time new children (siblings of C1) are introduced. To avoid this duplicate task, I think using nested supanes makes sense. But I don't know the best way to do it. Any advice is appreciated 🙂

 

Thank you

TailOfGon
Certified LabVIEW Architect 2013
0 Kudos
Message 1 of 7
(2,944 Views)

Don't ever use nested subpanels

 

BAD BAD things happen

- James

Using LV 2012 on Windows 7 64 bit
Message 2 of 7
(2,934 Views)

See these two threads and be sure to read them thoroughly and follow the links:

 

http://forums.ni.com/t5/LabVIEW/An-experiment-in-creating-compositable-user-interfaces-for/m-p/12623...

http://forums.ni.com/t5/LabVIEW/A-more-successful-experiment-in-creating-compositable-user/m-p/12768...

 

 


___________________
Try to take over the world!
Message 3 of 7
(2,917 Views)

Hi, James

 

Did you mean not to use nested subpanels in general or in this specific situation? It would be great if you can explain it based on your experience 🙂

TailOfGon
Certified LabVIEW Architect 2013
0 Kudos
Message 4 of 7
(2,876 Views)

Thank you tst.

 

I looked at the examples posted on the links. The way to use a picture control there was very insteresting and creative. I also liked the dynamic dispatching capability it provides as well as the flexibility. 

 

It would be great if I can just start using the library to create my configuration window... however, my configuration window has some dynamic elements. For example, it has a string control which can get disabled depending on the status of a checkbox control right above it. The picture control solution does not have a solution for such cases.

 

 

TailOfGon
Certified LabVIEW Architect 2013
0 Kudos
Message 5 of 7
(2,859 Views)

Well, as both AQ and I said in those threads, the things we posted are experiments, not completed frameworks. Personally, I prefered the way I went (see my posts in those threads) and you might prefer it as well, but it also has its issues.


___________________
Try to take over the world!
0 Kudos
Message 6 of 7
(2,852 Views)

Thank you tst

 

I took a brief look at your code (Class Hierarchy Config). The behavior is what I was trying to accomplish. Also, I liked that you can select how you want to display the dialog. I am going to look at it deeper later this month.

 

Thank you!

TailOfGon
Certified LabVIEW Architect 2013
0 Kudos
Message 7 of 7
(2,838 Views)