10-28-2010 04:01 PM
I'd like to see an example of how to programmatically generate a new front panel object like a button or sub-panel at run time. Any pointers?
I've looked for examples but don't seem to be having success.
10-28-2010
04:07 PM
- last edited on
06-04-2024
04:02 PM
by
Content Cleaner
Hi,
Actually you can't ! LabVIEW doesn't allow dynamic control creation. It must know how many controls needs to be loaded at run-time.
There is a trick where you can use subPanel and re-entrant VIs but this is not really dynamic.
Also if you don't plan to compile your VI you might be interested in VI Scripting to dynamically create controls in VIs.
Regards,
10-28-2010
04:19 PM
- last edited on
06-04-2024
04:03 PM
by
Content Cleaner
Have a look at this thread : https://forums.ni.com/t5/LabVIEW/How-can-I-dynamically-quot-create-quot-controls-or-indicators/td-p/...
10-29-2010 08:19 AM
"Controls on the fly" (artwork courtisy of Christian Altenbach) is something I have done on more than one app.
Also check out the Picture control thread for more links and idea.
The easy method is to pre-create and hide.
The amount of code that goes into supporting functional controls is enormous (been ther done that)
Ben
10-29-2010 03:44 PM
Try this.
07-30-2013 06:53 AM
@paul_a_cardinale wrote:
Try this.
This is great, thank zou very much! This is exactly what I needed for a labview code generator!