NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Why ApplicationMgr.ExecutionClosed event returns wrong object

Solved!
Go to solution

Work with Labview operator interface.

I'm trying to get event when sequence file is closed.

I have created two callbacks to ApplicationMgr.ExecutionClosed and ApplicationMgr.SequenceFileClosing events.

According to TS Help first callback returns Execution object and second callback returns SequenceFiile object.

Both callbacks are automatically created Labview and have only argument from API to pass it to event handler.

 

In both Labview event handlers I use property nodes to get ID for objects (execution and file)..

Both property nodes generate errors #1 with reason: property node has wrong argument 1 (object reference as I undertand).

When I use conversion to varianr I view not empty reference in event parameter..

It very like as value returned EntryPoint.Run method for execution and OpenSequenceFile for ApplicationMgr.

 

What may be wrong?

Something is happened in memory or this behaviour is result of my wrong actions?

0 Kudos
Message 1 of 5
(3,224 Views)

Hi anpis,

 

I hope you are doing well today!  Could you provide a screenshot of your block diagram that shows this?  Also, just to clarify, did you create these callbacks within LabVIEW, or are they callbacks in TestStand?  Could you also provide a screenshot of the error message that you are seeing?  Thanks, anpis.  Have a great day!

Taylor G.
Product Support Engineer
National Instruments
www.ni.com/support
0 Kudos
Message 2 of 5
(3,190 Views)
Solution
Accepted by topic author anpis

Hi, Taylor

 

Thanks for responce.

Today I have solved this problem.

The reason was wrong understanding event handling in Labview.

 

I passed sequence file reference from callback VI into LV event handler and then tried to get file ID in LV event loop and close the reference.

This way was wrong

File reference here is bad.

 

After I have changed getting file ID directly into callback VI I have normal work.

 

0 Kudos
Message 3 of 5
(3,181 Views)

Hi, Taylor

 

Thanks for responce.

Today I have solved this problem.

The reason was wrong understanding event handling in Labview.

 

I passed sequence file reference from callback VI into LV event handler and then tried to get file ID in LV event loop and close the reference.

This way was wrong

File reference here is bad.

 

After I have changed getting file ID directly into callback VI I have normal work.

 

0 Kudos
Message 4 of 5
(3,181 Views)

Hi anpis,

 

I am glad to hear it is now working successfully.  Thanks for the update.  Have a great day, and good luck with your project!

Taylor G.
Product Support Engineer
National Instruments
www.ni.com/support
0 Kudos
Message 5 of 5
(3,170 Views)