MagicWand Posted June 1, 2005 Report Share Posted June 1, 2005 I've tried to do some GOOP in LV 6.02 and I wanted to use Named objects/instances. It is fairly easy to set the name of an object, but then if I want to read the name of the object later on, how do I do that? The private functions "Get Data" and "Get Data to Modify" only return the Data from the Object repository, not the name. Of course I can in addition call the Object repository using the input method "Get Statistics", but is this the only way to get hold of the name? I don't want the statistics, I only want the Data and the name in one go. And I also don't want to store the name as part of the Data as what could be another solution. Quote Link to comment
Jan Klasson Posted August 22, 2005 Report Share Posted August 22, 2005 I've tried to do some GOOP in LV 6.02 and I wanted to use Named objects/instances.It is fairly easy to set the name of an object, but then if I want to read the name of the object later on, how do I do that? The private functions "Get Data" and "Get Data to Modify" only return the Data from the Object repository, not the name. Of course I can in addition call the Object repository using the input method "Get Statistics", but is this the only way to get hold of the name? I don't want the statistics, I only want the Data and the name in one go. And I also don't want to store the name as part of the Data as what could be another solution. 4914[/snapback] In the Endevo GOOP (GOOP Wizard 1, 2 or 3) you use the "new" VI to retreive the ref from a string name. If you are using openG it probably works the same. Jan Klasson Endevo Quote Link to comment
m3nth Posted August 22, 2005 Report Share Posted August 22, 2005 In the Endevo GOOP (GOOP Wizard 1, 2 or 3) you use the "new" VI to retreive the ref from a string name. If you are using openG it probably works the same.Jan Klasson Endevo 5764[/snapback] I believe the question was, "How can I obtain the class name from the reference?", not "How can I obtain the class reference from the name?". Maybe if you knew all the names you've assigned for that class then you could look up all the references and find a match. Not a direct solution but that might possibly be a workaround. Quote Link to comment
Mark Balla Posted August 23, 2005 Report Share Posted August 23, 2005 I've tried to do some GOOP in LV 6.02 and I wanted to use Named objects/instances.It is fairly easy to set the name of an object, but then if I want to read the name of the object later on, how do I do that? The private functions "Get Data" and "Get Data to Modify" only return the Data from the Object repository, not the name. Of course I can in addition call the Object repository using the input method "Get Statistics", but is this the only way to get hold of the name? I don't want the statistics, I only want the Data and the name in one go. And I also don't want to store the name as part of the Data as what could be another solution. 4914[/snapback] I've done this for my Open-G Goop model can you figure out how the names are extracted in the statistics vi. If you can I would move the code outside of the case structure so the name is generated for all cases inside the repository. Quote Link to comment
m3nth Posted August 23, 2005 Report Share Posted August 23, 2005 I've done this for my Open-G Goop model can you figure out how the names are extracted in the statistics vi.If you can I would move the code outside of the case structure so the name is generated for all cases inside the repository. 5781[/snapback] Ok so that's the answer: The name is returned by the Object Inspector.vi in the Statistics Cluster and you can essentially do the same thing by just calling the Class Repository with the given reference and the Get Statistics enum for the Method input. 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.