LabVIEW

cancel
Showing results forĀ 
Search instead forĀ 
Did you mean:Ā 

How do I apply properties to a control refnum from another VI and whose type I know?

Solved!
Go to solution

Hi,

 

I have programmatically retrieved the Control refnum of a Table running on a separate VI. I search for its name and when match ocurrs I would like to use its control refnum to change som cell values in it by either the Invoke node or Property node. Nevertheless even though I know it is a Table I am not allowed to wire the control refnum to a property node with "Active cell", "BG color" et.c. I am not either allowed to wire it to an Invoke node with the method "Set Cell Value".

 

Is there a work around for this?

 

 

 

0 Kudos
Message 1 of 10
(3,742 Views)
Solution
Accepted by RealBjƶrkis

You have to use the "to more specific class" function in the application control palette.

 

hope this helps,

Norbert 

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 2 of 10
(3,739 Views)

hi,

Afer matching that control refnum convert that refnum to table refnum of what ever you want as shown in fig after that you will get that options 

untitled.JPG

ihope this will help you

Regards,
Santhosh M
Message 3 of 10
(3,733 Views)

Thanks Norbert.

 

Your solution helped.

Santhosh I will try out your solution too. Thanks.

 

 

0 Kudos
Message 4 of 10
(3,728 Views)

Oops. I thought I could choose two accepted solutions. If a had to choose now afterwards I would chose Norberts solutuions since it was posted first. Sorry Norbert, I made a misstake.

0 Kudos
Message 5 of 10
(3,725 Views)

Well, i assume that Santhosh solution works too (i hope he tested it before šŸ˜‰ ). So no mistake here. Still, if you like, you can take the "solution" flag back from a post and redistribute it....

 

Norbert 

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 6 of 10
(3,720 Views)

Ok, I know now how to unmark solutions.

Sorry Santhosh, what is fair is fair.

0 Kudos
Message 7 of 10
(3,703 Views)
You can provide Kudos for good answers as well šŸ™‚
Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 8 of 10
(3,698 Views)

Aha, is that what it means.

Ok Santhosh received a Kudos then.

0 Kudos
Message 9 of 10
(3,687 Views)
You should NOT use the type cast method. It works because of the way references are implemented, but it's a dangerous option because it allows you to convert any reference to any other reference, even with the potential to crash LabVIEW. The TMSC primitive is the one you should use, and it will return an error at run-time if the reference does not actually point to a control of that class.

___________________
Try to take over the world!
Message 10 of 10
(3,683 Views)