01-19-2012 05:29 AM
Hi, i am writing software for driving electromotors. I am informed as global vi are not the best option to transfer data from vi to subvi. How to replace them with references/refnums?
Here is my app.
Main is Demo coolmuscle driver.
01-19-2012 11:54 AM
01-19-2012 12:27 PM
You are aware of that you can handle multiple user event in one event handler, right ?
01-20-2012 05:08 AM
Yeah, but that's not the case. I want to change control with refnums.
I dont know how to wire reference into subvi, which already exists to make refnum control in the subvi. I know the principle of how it's done in making a new subvi, but not in existing subvi.
01-20-2012 06:00 AM
Right click on a control and chose create>>reference.
In the application controls pallete, chose Property node and wire the reference to it.
Highlight the property node and under Edit Menu, select create subVI. Voila!
01-20-2012 06:11 AM
Hi
Attached is a set of VIs that pass data from main vi to sub vis. See if this will help you.
All the best
01-20-2012 07:42 AM
This albumn has images realted to what I call a GUI controller where I access FP object from sub-VIs. It may give you some ideas. Please note those images have links to where they were originally posted so if you want to read more, chase down those links.
Have fun!
Ben