From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Replacing controls via scripting without Typedef or Menu string

I'm working on some scripting routines to parse the private data of a class and create not only accessors but also other accessory VIs for a class design I'm trying out.  I have the accessor creation more or less worked out (scripting is great BTW) but I have an associated question.  In order to be able to replace the existing wired-up class controls with "proper" ones, I  simply use the "replace" function with the path to the class control file.  But when trying the same thing with the actual data field for the accessors, I normally don't have Typedefs so how exactly do I replace them.  In the IDE if I copy a control and then select the existing one and Paste, it gets replaced but programmatically, it adds a control instead.

 

How to achieve this without having to create a temporary typedef?  I mean, creating a temporary Typedef works but maybe there's a trick I don't know about?  Having to create a temporary Typedef seems like a lot of work for something so simple.

 

0 Kudos
Message 1 of 3
(2,598 Views)

Using a temporary .ctl is the only way I know how to do this...there is not a way in scripting to perform the handy Paste-Replace technique from the editor.

0 Kudos
Message 2 of 3
(2,562 Views)

OK, thanks. I thought maybe i was overlooking something.

0 Kudos
Message 3 of 3
(2,528 Views)