Jump to content

XControl: Difference between revisions

From LabVIEW Wiki
XControl Page Under Construction
 
Line 52: Line 52:
== Facade Ability ==
== Facade Ability ==
The Facade VI is the running heart of the XControl. It decides on which events applied to the XControl should be reacted in which ways.
The Facade VI is the running heart of the XControl. It decides on which events applied to the XControl should be reacted in which ways.
[[Image:XControl.xctl_Facade_Empty.png]]
[[Image:XControl.xctl_Facade_Empty.png|center|thumb|600px|Example XControl Facade VI showing the Timeout frame]]

Revision as of 09:05, 7 May 2007

XControls are introduced in LabVIEW 8.0 and enhance the power of front panel objects in great ways.

Essentially an XControl is a front panel object with dedicated code linked to react on certain user events.

An XControl exists of several parts, managed in a .xctl file. The .xctl file is a XML-file like the project-file. Other parts of the XControl are abilities. The following abilities are obliged

Ability Function Called if/when LabVIEW file type Optional?
Init To initialize memory, convert from previous version, load data from a previous session The first time a Xcontrol is added to a VI, an Xcontrol is upgraded, a VI with an XControl is opened Instrument (VI) No
Data Interface to the calling VI NA Control (ctl) No
State Contains local data for the XControl NA Control (ctl) No
Facade Contains the code running when the XControl is active Every time an event inside the Facade VI is triggered Instrument (VI) No
Uninit To close items allocated in Init The XControl is unloaded from memory Instrument (VI) Yes
Convert state for save Change the data that is saved inside a VI The VI containing the XControl is saved Instrument (VI) Yes


Facade Ability

The Facade VI is the running heart of the XControl. It decides on which events applied to the XControl should be reacted in which ways.

Example XControl Facade VI showing the Timeout frame