LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I remove a control created with NewCtrl?

Solved!
Go to solution

I'm creating controls dynamically with NewCtrl(). I now need to remove them and create different controls.

 

How do I remove/delete a control that I created with NewCtrl? 

0 Kudos
Message 1 of 3
(3,269 Views)
Solution
Accepted by topic author mikie

DiscardCtrl (); See the section 'Programming with Controls' in the help Smiley Wink

Message 2 of 3
(3,267 Views)

I looked up Delete and Remove but didn't think of "Discard"

 

The documentation for InstallCtrlCallback instructs the user that to remove the callback, a NULL should be used for the eventFunction parameter. 

 

Note  To uninstall the callback, pass NULL for eventFunction.

 

 Help documentation for NewCtrl makes no mention of how to remove the control. I would suggest adding this note to the Help documentation for NewCtrl.

0 Kudos
Message 3 of 3
(3,264 Views)