LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Popup sub VI without running

Solved!
Go to solution

Hello, I'm looking for advice to create a simple application.

The application have main window which is a main VI to select several SubVIs. If you select one of SubVIs,  the SubVI opens without running.

I see the following method is similar but the SubVI shows with running by this method. 

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019MBISA2&l=en-US

Could you tell me about this? Thanks.

0 Kudos
Message 1 of 16
(1,962 Views)

A non-running subVI is for editing. In an application, running (or reserved) is the only reasonable state. (The front panel can be shown or not).  If you implement the  subVI as a proper state machine, it could be in an idle state where it is just waiting for input.

 

Can you explain the reasoning behind your request? It makes very little sense.

0 Kudos
Message 2 of 16
(1,941 Views)

altenbatch, thank you for your prompt reply.

 

That make sense.

I have over 10 VI file for measurement and some VI share SubVIs.

I need to share these VI with many different people and let them to select one of these VIs with explanation easily depending on the situation.

Therefore, I want to create a window to summarize these VI and select and show one of them and without VI running.

Is it possible to achieve this kind of window with LabVIEW? or Need I use any other tools?

0 Kudos
Message 3 of 16
(1,913 Views)

If the VIs are used in the application, you can't open them without running.

 

The VIs don't need to execute when you open them, but they can't be idle. Technically, they won't be running top level, but running, and if you want them idle, it is simply not possible if they are used.

 

If the VIs are not used\running, it should be a simple Open VI Reference, Front Panel Open method to open it. And you can get a diagram reference and open it by it's Open property.

 

 

Message 4 of 16
(1,898 Views)

There is confusion over alternate uses of the term "running".  I would guess the OP wishes to show the subVI front panel without executing it, rather than without loading it onto the LabVIEW execution system.  

Message 5 of 16
(1,886 Views)

@drjdpowell wrote:

There is confusion over alternate uses of the term "running".  


Definitely.

 

Opening a VI without running it doesn't mean the VI opens idle (editable). I think that's what OP is looking for, but if the VI is used as a normal SubVI in a running VI, it's not possible.

 


@drjdpowell wrote:

 I would guess the OP wishes to show the subVI front panel without executing it, rather than without loading it onto the LabVIEW execution system.  


Could be. But still if the VI is used, it won't be idle. I think that's the problem, that the opened VI appears 'running'.

Message 6 of 16
(1,882 Views)

@drjdpowell wrote:

There is confusion over alternate uses of the term "running".  I would guess the OP wishes to show the subVI front panel without executing it, rather than without loading it onto the LabVIEW execution system.  


I suspect that you are correct. I believe that what the OP really needs to do is to restructure the subVIs so that they are in a waiting for input state. I see nothing in the post that indicates that the OP wants to edit the subvi before running. The OP could use a Start button, for instance, to signal the program to start "running." A Panel Close event could be used to stop and close the ones that the OP wants to close.

Message 7 of 16
(1,864 Views)
Solution
Accepted by topic author Narry723

Maybe it would be easier to just take a screenshot of the front panel and save that as a .png.  Then show the .png file in a picture indicator.

 

Or you could use VI scripting methods to capture the image of the front panel straight from the subVI without ever truly "showing" the actual subVI.

Message 8 of 16
(1,856 Views)

@RavensFan wrote:

Or you could use VI scripting methods to capture the image of the front panel straight from the subVI without ever truly "showing" the actual subVI.


IIRC, that's VI Server. For a diagram image, you'd need scripting. And both could be problematic in an executable, if that's the plan. FP can be removed, diagrams will be removed for sure (and the method won't be available)...

0 Kudos
Message 9 of 16
(1,837 Views)

Perhaps something like this.

"If you weren't supposed to push it, it wouldn't be a button."
Message 10 of 16
(1,799 Views)