LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Passing a control reference from a main vi to a subvi via invoke note

Does any one know how to pass a control reference from a main vi to a subvi by using invoke method?  Thank you very much.
 
Dao
0 Kudos
Message 1 of 6
(2,703 Views)

Right Click on the control, and make a reference. Right Click on the Reference constant and make it a control. Move this control to the subvi, it is a control of the correct reference type to invoke methods from a subvi.

 

Paul

Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 2 of 6
(2,696 Views)
Thanks for your response.   That was exactly what I did, but I got Error 1 - "An input parameter is invalid."   I have no problem passing a control value to a subvi via invoke note, but some how I could not do it with a control reference.
 
Dao 
0 Kudos
Message 3 of 6
(2,687 Views)

A ""An input parameter is invalid."   error could be caused by passing a reference that has gone invalid because the entity that created the reference has gone idle (could have been edited).

Does the original creator of the reference stay active?

Ben

Message Edited by Ben on 06-07-2007 05:39 PM

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 4 of 6
(2,678 Views)

Sorry I assumed from the question that this was a reference to a control on a caller vi which stays opened so no reference managerment is needed.

 

Paul

Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 5 of 6
(2,663 Views)
Thank you all for helping.  It was my own mistake by specifying the name of the variable of the top vi instead of the subvi's.
It works now.  Again, I am very appreciated your contributions.
 
VR,
 
Dao
0 Kudos
Message 6 of 6
(2,652 Views)