Matteo Posted November 18, 2010 Report Share Posted November 18, 2010 Hi all, I don't know if it's possible, but I would like to be albe to read the path of a Caller inside the subvi. Let's say that I have many VIs call Mater 1.vi, Master 2.vi, Master 3.vi ..... and a VI call Slave.vi. The Slave.vi is a subvi of all masters Is it possible create a code inside the Slave.vi in way to know which is the name of the caller? o_O Something that tell me if the caller is Master 1.vi or Master 2.vi ..... Quote Link to comment
Christian_L Posted November 18, 2010 Report Share Posted November 18, 2010 Hi all, I don't know if it's possible, but I would like to be albe to read the path of a Caller inside the subvi. Let's say that I have many VIs call Mater 1.vi, Master 2.vi, Master 3.vi ..... and a VI call Slave.vi. The Slave.vi is a subvi of all masters Is it possible create a code inside the Slave.vi in way to know which is the name of the caller? o_O Something that tell me if the caller is Master 1.vi or Master 2.vi ..... That's a pretty standard operation using the Call Chain node in LabVIEW. Quote Link to comment
PaulL Posted November 18, 2010 Report Share Posted November 18, 2010 OK, this doesn't answer your question directly, perhaps, but can you explain further what you are trying to accomplish by doing this? I can imagine a situation where a method (your subVI) operates on any of a number of instances of some component. In an Object-Oriented world I would instantiate an object for each instance of the component and then pass that object as an input to the subVI. Certainly one could do a similar thing without objects by passing some sort of reference (could be just a VI name) from the caller to the subVI. Does this get you any closer to what you are trying to accomplish? Quote Link to comment
Matteo Posted November 18, 2010 Author Report Share Posted November 18, 2010 The Call Chain is exactly the instrument that I was looking for. @ Paul: I agree with u, but sometimes we have to modify a code without adding any input or output, that's my situation. Thanks a lot Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.