ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Main GUI module with sub-modules

Dear all,

 

I am doing some 3D real-time measurements along with object detection/tracking. Currently, all my program modules (initialize, acquire, display, analize,...) are a part of the same .vi.

 

It would suit my needs better if these were in fact seperate modules that can be accessed via a main GUI application (the common denominator for all modules should be a path to a file or folder, etc...). For example:

 

image.png

 

So, when I run the "Untitled 1", I can select the individual modules. When I select the "Initialization" for example, I would want that the "Untitled 1" still runs in the background (with some intuitive loop delay to not load the CPU) and that a new .vi opens (and runs automatically). So, when I close the newly opened .vi, I can return to the main GUI ("Untitled 1) and continue working...

 

What would be the best / easiest way to do this?

 

Thank you and best regards,


https://decibel.ni.com/content/blogs/kl3m3n



"Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."
0 Kudos
Message 1 of 5
(2,885 Views)

Use a queued event-driven producer consumer loop with each of your subVIs set up to pop up in your consumer cases.  The event-driven producer loop queues up elements, which are dequed in the consumer loop.  This is a standard design pattern and a template for one take on this is found in the built in help.

0 Kudos
Message 2 of 5
(2,849 Views)

Hi Klemen,

 Please have a look at the VI which will open the VI from another VI.

 

Regards,

SrikrishnaNF

Regards,
Srikrishna


Download All
Message 3 of 5
(2,839 Views)

Hello,

 

thank you for the prompt answers.

 

@carlos_camargo:

 

In this case, I think the producer - consumer loop will make things more complicated...

 

@srikrishnaNF:

 

This seems like a really simple solution. Do you use such technique to handle simple dialogs as well as more complex?

I will try this, since it looks promising in my case.

 

I will post back about the situation when I get things working.

 

Best regards,

K


https://decibel.ni.com/content/blogs/kl3m3n



"Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."
0 Kudos
Message 4 of 5
(2,827 Views)

Hi Klemen,

 

   That SUBVI based pop up dialog can handle more complicated as this is implemented as a sub-VI.

    Please post your progress in the application in forum.

Regards,

SrikrishnaNF

Regards,
Srikrishna


0 Kudos
Message 5 of 5
(2,810 Views)