LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Community Nugget: Class GUI/FP handling using a XControl with sub-panels

Hi all,

 

Here's a take on how to use XControls, sub-panels and LVOOP for simplified gui handling using subpanels with VI ref's.

 

The block diagram becomes quite tidy if all the gritty sub-panek & FP details are handled by the XControl:

BlockDiagram.JPG

 

And the front panel (sub panel) looks like this:

Running.JPG

 

It is slightly similar to the action engines for example found in:

http://forums.ni.com/t5/LabVIEW/Community-Nugget-GUI-Components-using-Sub-Panels/td-p/1707270

 

A more extensive example(s) of this idea can be found at:

https://decibel.ni.com/content/docs/DOC-25242

https://decibel.ni.com/content/docs/DOC-25243

https://decibel.ni.com/content/docs/DOC-24602 (older queued api)

 

If you find it useful and can give some inspiration, feel free to comment.

However, the XControls on the PIDRegulator:gui.vi is a bit arcane and I haven't gotten round to improve them, don't flame too hard on those. 🙂

 

Attached is an example for LV2011.

 

Regards,

 

/Roger

 

Message 1 of 5
(3,762 Views)

Without having yet looked at the code, Kudos for sharing.

 

I've been exloring this avenue a lot recently (If my assumptions are correct) and I think it's an extremely powerful and tidy yet extendable way of doing things.

 

I look forward to looking at the code eventually when I get time.

 

Shane.

Message 2 of 5
(3,732 Views)

@Intaris wrote:

Without having yet looked at the code, Kudos for sharing.

 

I've been exloring this avenue a lot recently (If my assumptions are correct) and I think it's an extremely powerful and tidy yet extendable way of doing things.

 

I look forward to looking at the code eventually when I get time.

 

Shane.


Thanks Shane,

 

Yes, I am hoping it will help sort out some of the LV GUI annoyances, specially with LVOOP. I was also considering some fancier GUI stuff with sub-panels for header, footers, borders and such, but I gave it up.

 

What made me stop was wondering if LV is best GUI solution. Perhaps a better idea would be to go towards some other text based XAML/QML UI framework if it's an elaborate undertaking.

 

Br,

 

/Roger

 

0 Kudos
Message 3 of 5
(3,713 Views)

Thank you Roger!  That example certainly does offload a lot of functionality to the heavy lifters behind the scenes.  (So much so that it took a while for me to figure out what it did)

 

Kudos and don't forget to unregister your events!Smiley Wink


"Should be" isn't "Is" -Jay
Message 4 of 5
(3,700 Views)

@JÞB wrote:

Thank you Roger!  That example certainly does offload a lot of functionality to the heavy lifters behind the scenes.  (So much so that it took a while for me to figure out what it did)

 

Kudos and don't forget to unregister your events!Smiley Wink


You are welcome, thanks for the comments!

 

Fixed the unregistering. Bummer.. Smiley Tongue

 

Br,

 

/Roger

 

0 Kudos
Message 5 of 5
(3,681 Views)