LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Need Script to Create Event Registration Refnum Control

Solved!
Go to solution

Given a typedef, I want a script to create a control that's an event registration refnum control for a user event of that data type.

s1.png c1.png

I've tried the "New VI Object" function, but I can't figure out what "style" to use:

s2.png

 

I could do it by manipulating a scratchpad VI, but there ought to be a cleaner solution.

"If you weren't supposed to push it, it wouldn't be a button."
0 Kudos
Message 1 of 4
(1,282 Views)
Solution
Accepted by topic author paul_cardinale

Start off with a scratch control that contains a user event reference of any type. Then drop your cluster typedef on the panel of the scratch panel. Then use the Move method to move the cluster control into the user event reference to set its type.

 

This is the only way to accomplish the task that I know of. Well, other than scripting the diagram you showed above and doing 'Create Indicator' on the Create User Event function...

0 Kudos
Message 2 of 4
(1,252 Views)

 paul_cardinale,

 

You marked this issue as solved. Could you post a screenshot of the solution, please? 

 

Thanks!

0 Kudos
Message 3 of 4
(1,036 Views)

@null_and_void wrote:

 paul_cardinale,

 

You marked this issue as solved. Could you post a screenshot of the solution, please? 

 

Thanks!


Sorry.  I don't remember which project that was, much less which VI.

Just follow Darren's instructions.

"If you weren't supposed to push it, it wouldn't be a button."
0 Kudos
Message 4 of 4
(1,028 Views)