Showing results for 
Search instead for 
Did you mean: 

using one VI to open another stand alone program

Go to solution

Hey guys,


I would like for my program to be started by the user and have them make some selections that would then open a new stand alone program. Where each individual new program would actually be the bulk of the program as a whole and maybe utalize its own probably producer consumer design pattern. once the secondary program finishes I would like it to go back to the initial program for the user to make new selections and open another prgram.


to me this feels do able like basically having a main loop that only calls functions.


If some one could just link me an article or something that would be great. I was looking around and found something about this call chain VI, is that part of what I would need?


also I'm always open to suggestions if this seems like the hard way to go or an improper way of doing this.


Thanks guys

0 Kudos
Message 1 of 6

I think this might be what you are looking for:


Let me know if tha answers your question or if you are looking for something else.





0 Kudos
Message 2 of 6

No, when I say new program I mean sub VI but its not just open sub vi do one thing and come back, its like ask user something, open sub vi and most of program is in sub vi then come back and ask user to select a new sub VI.


the sub VI would have its own front pannel that the user will interact with.


I may just be over complicating what Im thinking needs to happen.

0 Kudos
Message 3 of 6
Accepted by topic author pathare535

You can do this visually by adjusting the visual settings on your VI's.


I usually use a custom setting and call the Front Panel.Window.State property on your VI's,  It'd look something like this:Capture.png


Do the inverse on your subVI and you'll get an interupt. You'll also have to make some changes to the Window Appearence section of VI Properties.



That will give you a visual appearance and the kind of interupt you are looking for.  You'll also probably want to use an Event structure as your main loop function.  





0 Kudos
Message 4 of 6

awesome, thanks! is there some kind of event that is on VI open or start or something like that?

0 Kudos
Message 5 of 6

Nope, Vi's naturally interupt so as long as your want to 'fire and wait' so to speak, this method will work fine for what you want.  Change your window settings and play around with the VI property a bit and you'll get it going. Remember to change the settings on your SubVI's window appearance so that it will pop up when called. I do this quite often with the programs I write.  If you run into a snag drop another comment.





0 Kudos
Message 6 of 6