LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can't reopen a activex player I a popup.

Solved!
Go to solution

Hi

 

I have a popup that plays a video file. First time I open it works, but not the second time.

I keep the refrerence in a shift register.

 

If I never close the popup I don't get the problem. I think labview is messing with the reference when the window is closed.

0 Kudos
Message 1 of 6
(2,861 Views)

VideoPopup.jpg

0 Kudos
Message 2 of 6
(2,851 Views)

Run state and init are shifted in the picture

0 Kudos
Message 3 of 6
(2,849 Views)
Solution
Accepted by topic author magnuslilliehook

Hi Magnus

 

The behavior I get is that the video plays fine the first run, in subsequent runs it still plays, but no image is shown. I think this is because as you call the VI as a subVI it is loaded in memory at loadtime and doesn't leave memory until the main VI is closed and this somehow messes up the Media Player control. I rewrote your example to call the VI dynamically and that worked like you want it to run. I'm attaching my example. I wrote it so it would function like your example, there are some  things I would do differently, chief among those is to change the "Wait until Done" setting on the Run method to false so you don't lock the front panel of the main VI while the clip is running.

 

Best Regards

 

David

NISW

 

PS. The VIs are in version 2010, let me know if you need them in another version

0 Kudos
Message 4 of 6
(2,814 Views)

 

Your solution works perfectly.

Thanks for your help=)

0 Kudos
Message 5 of 6
(2,800 Views)

no problem, happy to help

 

Best Regards

 

David

0 Kudos
Message 6 of 6
(2,794 Views)