Control class: Difference between revisions
mNo edit summary |
mNo edit summary |
||
Line 1: | Line 1: | ||
{{VIServerClass| | {{VIServerClass|6}} | ||
{{stub}} | {{stub}} |
Revision as of 19:16, 1 September 2019
VI Server Class Information | |
---|---|
Return to VI Server Class Hierarchy | |
Class Name | Control class |
Class ID | 6 |
Scope | Basic Development Environment |
Class Inheritance |
|
Class Children |
![]() |
This article is a stub. You can help LabVIEW Wiki by expanding it. Please improve this article if you can. |
The Control class is a class in the VI Server Class Hierarchy, (see also VI Server).
Properties
Show/Hide Control Properties Table
Legend | |
---|---|
R/W | Readable/Writable Permissions |
RTE | Available in the Run-Time Engine |
Basic Development Environment | |
VI Scripting | |
Private | |
Deprecated |
Property ID | Short Name (English) | Description | R/W | RTE | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
633201C | Auto-Update | If TRUE, the control automatically updates when the type definition changes. | R/W | X | ||||||||
633201D | BitAccurateDataSize | R | X | |||||||||
6332003 | Blinking | If TRUE, the control blinks.
Keep in mind the following caveats when using this property:
This property is similar to the Blink Foreground and Blink Background options on the Environment page of the Options dialog box, and to the Blink delay for front panel controls (milliseconds) option on the Front Panel page of the Options dialog box. |
R/W | X | ||||||||
633203F | BuiltInMouseWheelSupport | Sets the conditions under which the control responds to mouse wheel movement.
For example, you can specify whether a control responds when you either hover over the control or the control has key focus. This property is similar to the Built-In Mouse Wheel Support option on the Key Navigation page of the Properties dialog box.
|
R/W | X | ||||||||
6332026 | C Type | R | X | |||||||||
6332004 | Caption | Reference to the caption object. You can use this reference with the Text properties.
Note You first must create the caption before you use this property, or LabVIEW returns an error. LabVIEW creates the caption the first time you set the caption to visible. This property is similar to the Visible Items»Caption option on the shortcut menu of front panel controls and the Caption Visible and Caption Text item on the Appearance page of the Properties dialog box. |
R | X | ||||||||
6332040 | ControlIndex | Gets the index of the control or indicator you specify. If the control or indicator for which you want to get the index does not have a terminal on the block diagram, this property returns an error.
You can use this property to specify the controls for which you get or set values with the Get Control Values by Index or Set Control Values by Index functions.
|
R | X | ||||||||
6332009 | CtrlRefNodes() | Returns references to the control reference nodes of this control. | R | |||||||||
633202D | BindingType | Returns the type of binding. | R | X | ||||||||
633202E | BindingBlinkOnAlarm | R/W | X | |||||||||
633202B | BindingLEDVisible | Shows or hides the data binding indicator. | R/W | X | ||||||||
6332029 | BindingMode | Gets or sets the mode of the data connection. | R/W | X | ||||||||
6332028 | BindingPath | Reads or writes the NI Publish-Subscribe Protocol (NI-PSP) URL to which the control is connected. To write this property, you must bind the control to the PSP URL before you begin writing.
Note If the control is bound to a project item instead of a PSP URL and you attempt to write this property, this property returns an error. To bind the control to a PSP URL, use the Bind to Network Path method while the VI is not running. |
R/W | X | ||||||||
633202C | BindingPersistID | R | X | |||||||||
633202A | BindingStatus | Returns the status of the data connection. The connection status can be Invalid Status, Unconnected, Active, Idle, Error, or Connecting.
|
R | X | ||||||||
6332017 | DtSktEnbld | This is the enabled state of the opc, ftp, and http connection on Windows, and the dstp and file connection on all LabVIEW-supported platforms. A connection can transfer data only when enabled. | R/W | X | ||||||||
633201E | DtSktLEDVisible | Shows or hides the connection status indicator. | R/W | X | ||||||||
6332016 | DtSktMode | Gets or sets the mode of the data connection. | R/W | X | ||||||||
6332018 | DtSktStatus | Returns the status of the data connection. The connection status can be Invalid Status, Unconnected, Active, Idle, Error, or Connecting.
|
R | X | ||||||||
6332015 | DtSktURL | Gets or sets the URL to which the control is connected. Valid URLs for using the DataSocket properties to connect controls are the opc, ftp, and http protocols on Windows, and the dstp and file protocols on all LabVIEW-supported platforms.
To set the URL, use the Attach DataSocket and Remove DataSocket methods when the VI is not running. Use front panel data bindings to bind controls to shared variables or to NI Publish-Subscribe Protocol (NI-PSP) data items. |
R/W | X | ||||||||
633200E | DefVal | Default value of the control (LabVIEW variant). | R/W | X | ||||||||
6332043 | DefVal (Undo) | W | ||||||||||
633200F | Desc | Description of the front panel object that appears in the Context Help window when you move the cursor over the object and in VI documentation you generate.
You can format the text in the description to appear bold in the Context Help window. If you want to display a carriage return in the Context Help window, you must separate paragraphs with two carriage returns This property is similar to the VI description text box on the Documentation page of the VI Properties dialog box. |
R/W | X | ||||||||
633203D | Disabled | Indicates whether you can operate the control.
This property is similar to Advanced»Enabled State item on the shortcut menu of a front panel control or indicator and to the Enabled State option on the Appearance page of the Properties dialog box. |
R/W | X | ||||||||
6332010 | FocusKeyBind | Sets a shortcut key to navigate to this control.
This property is similar to the Focus option on the Key Navigation page of the Properties dialog box.
|
R/W | X | ||||||||
633203C | Genericity | R/W | X | |||||||||
633202F | GrowInfo | Returns the growing abilities for this control. | R | X | ||||||||
6332030 | GrowInfoGrowHoriz | Returns if this control can grow horizontally. | R | X | ||||||||
6332031 | GrowInfoGrowVert | Returns if this control can grow vertically. | R | X | ||||||||
6332034 | GrowInfoMaxHoriz | Returns the maximum size horizontally this control can grow. | R | X | ||||||||
6332035 | GrowInfoMaxVert | Returns the maximum size vertically this control can grow. | R | X | ||||||||
6332032 | GrowInfoMinHoriz | Returns the minimum size horizontally this control can grow. | R | X | ||||||||
6332033 | GrowInfoMinVert | Returns the minimum size vertically this control can grow. | R | X | ||||||||
6332022 | HasCaption | Returns TRUE if the control has a caption.
A control has a caption after you complete one of the following actions:
Note LabVIEW continues to store the caption for the control even if you hide the caption or use the text editor tool to delete the text of the caption. This behavior enables LabVIEW to display the caption if you choose to make it visible again. Therefore, this property continues to return TRUE for hidden captions. |
R | X | ||||||||
6332007 | Indicator | If TRUE, the front panel object is an indicator. If FALSE, the object is a control. | R/W | X | ||||||||
633200C | InvokeNodes() | Returns references to the invoke nodes of this control. | R | |||||||||
6332020 | IsOnConPane | Returns whether a control or indicator is on the connector pane of a VI. | R | X | ||||||||
633203B | Is Stub? | R | X | |||||||||
633201A | Typedef? | Returns whether the control is linked to the type definition. | R | X | ||||||||
6332002 | KeyFocus | If TRUE, the control has key focus and receives the keys pressed on the keyboard. | R/W | X | ||||||||
6332005 | Label | Reference to the label object.
You can use this reference with the Text properties. |
R | X | ||||||||
633201F | LatchValue | R/W | X | |||||||||
633200A | LocalVars() | Returns references to the local variables of this control. | R | |||||||||
633203E | OwningPane | Returns a reference to the pane that owns the referenced control.
For nested controls, this property returns a reference to the pane that owns the object that contains the control. For example, if you use this property on a control within a tab control, the property returns a reference to the pane that owns the tab control. If the referenced control is not on a pane, this property returns Not a Refnum. |
R | X | ||||||||
633200B | PropNodes() | Returns references to the property nodes of this control. | R | |||||||||
6332021 | SkipTabbing | If TRUE, LabVIEW skips this control when you tab through the front panel.
This property is similar to the Skip this control when tabbing option on the Key Navigation page of the Properties dialog box. |
R/W | X | ||||||||
633203A | Style ID | Returns the style of the control. | R | X | ||||||||
6332008 | SyncDisp | When TRUE, enables synchronous display that shows every update to a data value in a control or indicator. When FALSE, asynchronous display permits the execution system to reduce updates to a slower rate and spend more time executing VIs.
In multithreaded systems, you can use this property to set whether to defer updates for controls and indicators. With asynchronous displays, after the execution system passes data to front panel controls and indicators, it can immediately continue execution. This property is similar to the Advanced»Synchronous Display option on the shortcut menu of controls and indicators. You also can use the Defer Panel Updates property to defer all new requests for front panel updates. |
R/W | X | ||||||||
6332006 | Terminal | Returns the reference to the block diagram terminal of this control. Use this property to navigate between the front panel and the block diagram of a VI. | R | |||||||||
6332014 | TipStrip | Sets or returns the tip strip of a control. A tip strip is the brief description of the object that appears when you move the cursor over the object.
Other products refer to tip strips as tooltips. |
R/W | X | ||||||||
633201B | TypedefPath | Returns the path to the type definition if the control is linked to a type definition. Otherwise, LabVIEW returns an empty path. | R | X | ||||||||
6332025 | TypedefVI | Returns a reference to the type definition if the control is connected to a type definition. Otherwise, LabVIEW returns . | R | |||||||||
633200D | Value | Data value of the control (LV variant). If this is a Boolean value configured with a latching mechanical action, this property always returns an error. Due to race conditions that can occur when you have a Boolean value with latching mechanical action, you cannot programmatically read Boolean values that are set with a latching mechanical action. | R/W | X | ||||||||
6332023 | Val(Sgnl) | Sets the value of the control and generates a Value Change event.
This property updates the value of an object similar to the Value property. However, Value (Signaling) also causes LabVIEW to generate an event as if the user had interactively changed the value of the object. National Instruments recommends you use this property only when you rely on LabVIEW generating an event in response to the programmatic value change. If this is a Boolean value configured with a latching mechanical action, this property always returns an error. Due to race conditions that can occur when you have a Boolean value with latching mechanical action, you cannot programmatically read Boolean values that are set with a latching mechanical action. |
W | X | ||||||||
6332041 | Value (Undo) | W | X | |||||||||
6332000 | Visible | Displays the front panel control.
This property is similar to the Show Control and Hide Control options on the shortcut menu of a control. |
R/W | X | ||||||||
6332019 | WizData | R/W | X | |||||||||
6332037 | Container Bounds | Sets or gets the container bounds of the XControl. | R/W | X | ||||||||
6332039 | Height | Height of the XControl.
This property is an element of the XControl:Container Bounds property. |
R/W | X | ||||||||
6332038 | Width | Width of the XControl.
This property is an element of the XControl:Container Bounds property. |
R/W | X | ||||||||
6332036 | Is XControl? | Returns TRUE if the control is an XControl, FALSE otherwise. | R | X |
Methods
Show/Hide Control Methods Table
Legend | |
---|---|
RTE | Available in the Run-Time Engine |
Basic Development Environment | |
VI Scripting | |
Private | |
Deprecated |
Method ID | Short Name (English) | Description | RTE |
---|---|---|---|
6331C06 | AttachDataSocket | National Instruments recommends using front panel data binding through the Shared Variable Engine or using the Bind To Network Path method to attach a data connection to a control.
This method allows you to attach an opc, ftp, and http connection to a control on Windows, and a dstp and file connection to a control on all LabVIEW-supported platforms. You can add new connections only at edit time. This method is similar to the Data Binding Selection, Path, and Access Type options on the Data Binding page of the Properties dialog box. Note If you use this method with a Boolean control in a radio buttons control, this method returns an error. |
X |
6331C08 | Copy Wizard Template | ||
6331C01 | Create.Control Ref | Creates a control reference for the control and returns a reference to it. | |
6331C04 | Create.Invoke Node | Creates an Invoke Node for the control and returns a reference to it. | |
6331C02 | Create.Local Var | Creates a local variable for the control and returns a reference to it. | |
6331C03 | Create.Property Node | Creates a Property Node for the control and returns a reference to it. | |
6331C0F | DataBinding.Bind To Network Path | Binds a control to an NI Publish-Subscribe Protocol (NI-PSP) network path. You can add new connections only at edit time.
This method is similar to the Data Binding Selection and Access Type options on the Data Binding page of the Properties dialog box. |
X |
6331C11 | DataBinding.Bind To Network Variable | X | |
6331C12 | DataBinding.Unbind | Unbinds a control from an NI Publish-Subscribe Protocol (NI-PSP) network path. | X |
6331C14 | DataOp.CopyData | Copies data from the control to the clipboard. | X |
6331C15 | DataOp.PasteData | Pastes data from the clipboard to the control. | X |
6331C09 | Disconnect From Typedef | Disconnects the control from the type definition and returns TRUE. If the control is not connected to a type definition, LabVIEW returns FALSE. | |
6331C13 | FitControlToPane | Resizes the control to the size of the pane that contains it and sets the control to scale with the pane. | X |
6331C0C | Get Image | Returns an image of a front panel object.
This method is similar to the Front Panel:Get Image method. If a front panel is not visible, LabVIEW does not update the values in the objects on the front panel. If you call a VI whose front panel is not visible and you use the Get Image method to create an image of a front panel object, the image does not reflect any value changes that occurred when you ran the VI. If you want the image to reflect value changes, make sure the front panel is open before any values change. If you do not want to display the front panel but want the image to reflect value changes, create a Property Node from any terminal on the block diagram of the VI for which you want to create a front panel control image. You also can use the Append Control Image to Report VI to create an image of a front panel object and append it to a report. |
X |
6331C0D | Get Term Image | Returns an image of the block diagram terminal of a front panel object. | X |
6331C00 | Reinit To Default | Reinitializes the value of the control to the default value.
This method is similar to the Data Operations»Reinitialize to Default Value item on the shortcut menu of a control. Note If you use this method with a Boolean control in a radio buttons control, this method returns an error. |
X |
6331C07 | Remove DataSocket | Removes an opc, ftp, and http connection from a control on Windows, and a dstp and file connection from a control on all LabVIEW-supported platforms.
This method is similar to the Unbound option of the Data Binding Selection pull-down menu on the Data Binding page of the Properties dialog box. Note If you use this method with a Boolean control in a radio buttons control, this method returns an error. Use the Data Binding:Unbind method to remove psp connections. |
X |
6331C0E | Start Drag | Starts a drag and drop operation using the specified control as the source.
You can use this method to start drag and drop operations in response to user-defined actions instead of the built-in behavior with string, tree, listbox, and multicolumn listbox controls. For controls other than the string, tree, listbox, and multicolumn listbox, the Start Drag method is the only way to start a drag using this control as a drag source. You must specify what data to provide during the drag and drop operation. Optionally, you can specify the drag mode, and corresponding default cursor feedback, to reflect whether this drag and drop operation supports moving the data instead of only copying it. During a drag and drop operation, only drag and drop events are available. Mouse events are not available. If there is already a drag in progress, LabVIEW returns an error. If you pass an empty array for the data parameter, the drag operation does not start and LabVIEW returns an error. If the array of data passed contains duplicate data names or data that conflicts with built-in types, LabVIEW returns an error. After you use this method, LabVIEW remains in the middle of a drag and drop operation until the user cancels the drag by pressing the key or lifting the mouse button, or until a window opens in front of the window that has the source control. The Drag Data parameter is an array of clusters, each cluster containing a label and corresponding data. Each label must be unique and cannot use the LV_ prefix. Each element of the array must be of the same data type. The Drag Mode parameter specifies the operation of the drag, such as copy, move, or copy and move. If you select copy or move, pressing the <Ctrl> key copies the item. Example |
X |
6331C16 | Stub.Convert To Stub | ||
6331C17 | Stub.Revert From Stub | ||
6331C0A | Update Typedef | Updates the control from the type definition and returns TRUE. If the control is not connected to a type definition, LabVIEW returns FALSE.
In most cases, LabVIEW correctly preserves the default values of each instance when updating from the type definition. However, if LabVIEW is unable to map the previous default values to the updated controls or constants when updating instances, LabVIEW may lose or incorrectly preserve the default values of instances LabVIEW updates programmatically. Avoid updating type definition instances programmatically if the instances have custom default values and you plan to make extensive changes to the type definition. |
Events
Show/Hide Control Events Table
Legend | |
---|---|
Basic Development Environment | |
VI Scripting | |
Private | |
Deprecated |
Code | Name | Type |
---|---|---|
1073741869 | Drag Ended | Notify |
2684354617 | Drag Enter | Filter |
1073741885 | Drag Leave | Notify |
2684354618 | Drag Over | Filter |
2684354606 | Drag Source Update | Filter |
1073741867 | Drag Starting | Notify |
2147483692 | Drag Starting? | Filter |
2684354622 | Drop | Filter |
1073741847 | Key Down | Notify |
2147483658 | Key Down? | Filter |
1073741848 | Key Repeat | Notify |
2147483659 | Key Repeat? | Filter |
1073741836 | Key Up | Notify |
1073741842 | Mouse Down | Notify |
2147483655 | Mouse Down? | Filter |
1073741839 | Mouse Enter | Notify |
1073741838 | Mouse Leave | Notify |
1073741833 | Mouse Move | Notify |
1073741832 | Mouse Up | Notify |
1073741905 | Mouse Wheel | Notify |
2147483699 | Shortcut Menu Activation? | Filter |
1073741892 | Shortcut Menu Dismissed | Notify |
1073741878 | Shortcut Menu Selection (App) | Notify |
1073741876 | Shortcut Menu Selection (User) | Notify |
2147483701 | Shortcut Menu Selection? (App) | Filter |
1073741826 | Value Change | Notify |
History
![]() |
History information is needed. What changes have occured over previous versions? |
Version | Change(s) |
---|---|
![]() |
More info to come. |