LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

return from subVI

Norbert,
       I just found something quite interesting!  I am using an event handler in subVI A to catch when B is called.  To test whether execution was returning to "A" I created a 500ms timeout in my event handler and added a indicator on the loop index.  I found that the index IS incrementing, so the event handler is executing upon return from B, but somehow I still do not have the ability to interact with the UI.  HMMMM.  I still don't have a solution but I thought it was interesting nonetheless.
 
 
~goldie
0 Kudos
Message 11 of 14
(642 Views)
Goldie,

in your SubVI B, do you use any third party applications, like ActiveX-Servers, DLLs or exe?
I believe that the OS changes task, but since the UI from the task is hidden (or something like that), it cannot visually reflect that. Your Sub B works on like it should, but since LV does not have the focus from the OS, it cannot give Sub A the focus in regard to interaction. Why the bar reflects "active", i cannot explain.

If you are running in such an issue, you can use the Windows SDK to set the focus back to your LV-application.

hope this helps,
Norbert
Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
Message 12 of 14
(622 Views)

No I am not running anything other than a front panel in Sub B.  To make it even worse, I can move the window location of "Sub A" when it returns but I still have no functionality on the front panel.  

I finally solved the problem, after way to many hours of troubleshooting.  I went back to a previous version of my Sub A, put in the links to Sub B with the simple Vi in an event structure and everything works as planned.  Who knows??

Thanks for your time and for bouncing ideas back and forth.

~goldie

0 Kudos
Message 13 of 14
(606 Views)
Goldie,

good to know that you found a working solution to your issue 🙂
Nevertheless, i thought of somthing what could be a better solution for the future. This is maybe one of the best ways to display different sub VIs in a main: Subpanelcontrol.
If you havent heared about this, there is a good example provided with LV....

hope this helps,
Norbert
Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 14 of 14
(588 Views)