cpr.controls.ComboBox
ComboBox
A control that selects a single value from predetermined values.
Use a drop-down list.
Index
Event |
Description |
animationend |
Event that occurs after the animation ends. |
animationstart |
Event that occurs at the start of the animation. |
before-context-value-change |
Use a bind context in a control that has a bind context
An event that occurs before the value changes. |
before-selection-change |
Event that occurs before the selected value is saved by selecting the ComboBox Item. |
blur |
An event that occurs after the control loses focus. |
change |
DOM event that fires when the value changes. |
click |
An event that occurs when the user clicks the control. |
close |
This event occurs when closing the item list. |
context-value-change |
Use a bind context in a control that has a bind context
An event that occurs after the value changes. |
contextmenu |
When the right mouse button is clicked or the context menu key is pressed,
Event called. |
copy |
Event that occurs when a user copies the text. |
cut |
Event that occurs when a user cuts the text. |
dblclick |
An event that occurs when the user double-clicks the control. |
dispose |
The event that is called when the control is dispose. |
dragenter |
When the mouse pointer enters the elements included in the control while dragging
Events that occur. |
dragleave |
During the drag, the mouse pointer may have exited the elements contained in the control. |
dragover |
While dragging the source control with the mouse, the mouse pointer
An event that occurs when moving within a region. |
drop |
Drag the source control to the target control while dragging the source control with the mouse. |
focus |
The event that occurs after the control gains focus. |
input |
When the text displayed in the input box is input from the keyboard and changed
The event that occurs. |
item-click |
An event that occurs when an item is clicked. |
keydown |
Event raised when the user presses a key. |
keyup |
Event that occurs when the user releases the key. |
measure-size |
Event raised when calculating control size |
mousedown |
When the user presses the mouse button with the pointer over the control
Occurs when an event occurs. |
mouseenter |
An event that occurs when the mouse pointer enters the control. |
mouseleave |
If the user moves the mouse pointer beyond the control and its children
Events that occur when moving. |
mousemove |
This event is raised when the user moves the pointer over the control. |
mouseup |
The user releases the mouse button while over the control. |
open |
This event occurs when opening the item list. |
paste |
Event that occurs when a user pastes text. |
select |
An event that occurs when the user selects text. |
selection-change |
ComboBox An event that occurs after the selected item is selected to save the selected value. |
transitionend |
Event that fires after CSS property transition ends. |
transitionstart |
Event that fires when CSS property transition starts. |
Name |
Type |
Description |
accessKey |
String |
Returns the keyboard shortcut character. |
accessbility |
Accessbility |
Gets the accessibility-related ARIA properties or gets the context in which they can be specified. |
autoSelect |
Boolean |
Returns whether the entire data in the edit area is selected when it is focused. |
autoSkip |
Boolean |
Returns whether the focus moves to the next control when an item is selected in the list. |
buttonImage |
String |
Returns an image of button. |
dataSet |
DataCollection |
Returns the associated dataset. |
delimiter |
String |
Returns the delimiter when specifying or retrieving multiple selected values. |
displayExp |
#expression |
Returns the Expression of the text shown on the screen. |
displayingText |
String |
Gets the value of the HTML Element shown in the input. |
disposed |
Boolean |
Returns whether the control should be removed. |
dropDownType |
"list" | "tree" |
Returns the drop-down list type setting value. |
editable |
Boolean |
Returns whether the value can be changed by user action. |
enabled |
Boolean |
Returns whether the control is enabled. |
enabledItemExp |
#expression |
Returns the item's enabled expression value. |
fallbackValue |
String |
Returns the value to replace with the replacement value. |
fieldLabel |
String |
Returns the logical field name of the control. |
filterExp |
#expression<(item: cpr.controls.Item)=>Boolean> |
Returns the value of the expression that filters the item. |
fixedListWidth |
Boolean |
Returns whether the width of the open list is fixed to the combobox width. |
focusable |
Boolean |
Returns whether the control is focusable. |
focused |
Boolean |
Returns whether the control has focus. |
hideButton |
Boolean |
Returns whether to show or hide the Listbox button. |
id |
String |
Returns the ID of the control. |
itemSetConfig |
TreeItemSetConfig |
ItemSet Returns an object with the column name information of the dataset you set. |
maxVisibleItems |
Number |
Returns the value of the maximum number of list items. |
multiple |
Boolean |
Returns whether the item is multi-selected. |
name |
String |
Returns the name of the control. |
placeholder |
String |
Returns a text (hint) describing the expected value of the InputBox. |
preventInput |
Boolean |
Returns whether to prevent input through the inputbox. |
readOnly |
Boolean |
Returns whether a non-modifiable read-only mode is in effect. |
selectionViewIndex |
Number |
Returns the index position where the selection is shown when the popup is opened. |
showIcon |
Boolean |
Returns the value of whether to display the item's icon. |
style |
ComboBox$Styler |
Returns the style settings of the control. |
tabIndex |
Number |
Returns the control focus sequence using the Tab Key. |
text |
String |
Returns the text displayed on the screen. |
tooltip |
String |
Returns a description of the control |
treeExpandDepth |
Number |
Returns the depth value that automatically opens an item. |
type |
ControlType |
Returns the signature string of the Control's unique Type that can distinguish the Control. |
useFallbackValue |
Boolean |
Returns whether to change to an alternate value if it is an invalid value. |
uuid |
String |
Returns the unique ID of the control. |
value |
String |
Returns the value of the control. |
values |
String[] |
Returns an array of values stored in the control when multiple selections are made. |
visible |
Boolean |
Returns the style property for controlling css visibility. |
wheelRowCount |
Number |
Returns the number of rows to scroll at a time with the wheel. |
Constructor
Create a combo box.
name |
type |
description |
idoptional
|
String |
combo box id |
Events
CValueChangeEvent Use a bind context in a control that has a bind context
An event that occurs before the value changes.
CSelectionEvent Event that occurs before the selected value is saved by selecting the ComboBox Item.
The next event is a selection-change.
oldSelection: {cpr.controls.Item []} previously selected item pre>
newSelection: {cpr.controls.Item []} item whose selection will be changed pre>
CFocusEvent An event that occurs after the control loses focus.
CUIEvent DOM event that fires when the value changes.
CMouseEvent An event that occurs when the user clicks the control.
CUIEvent This event occurs when closing the item list.
CValueChangeEvent Use a bind context in a control that has a bind context
An event that occurs after the value changes.
CMouseEvent When the right mouse button is clicked or the context menu key is pressed,
Event called.
CMouseEvent An event that occurs when the user double-clicks the control.
CEvent The event that is called when the control is dispose.
CMouseEvent When the mouse pointer enters the elements included in the control while dragging
Events that occur.
CMouseEvent During the drag, the mouse pointer may have exited the elements contained in the control.
The event that occurs when.
CMouseEvent While dragging the source control with the mouse, the mouse pointer
An event that occurs when moving within a region.
CMouseEvent Drag the source control to the target control while dragging the source control with the mouse.
Event that fires when dropping.
CFocusEvent The event that occurs after the control gains focus.
CKeyboardEvent When the text displayed in the input box is input from the keyboard and changed
The event that occurs.
CItemEvent An event that occurs when an item is clicked.
item: {cpr.controls.Item} The item object you clicked on. pre>
CKeyboardEvent Event raised when the user presses a key. Keycode related constants can be referenced at
KeyCode.
CKeyboardEvent Event that occurs when the user releases the key. Keycode related constants can be referenced at
KeyCode.
CMouseEvent When the user presses the mouse button with the pointer over the control
Occurs when an event occurs.
CMouseEvent An event that occurs when the mouse pointer enters the control.
CMouseEvent If the user moves the mouse pointer beyond the control and its children
Events that occur when moving.
CMouseEvent This event is raised when the user moves the pointer over the control.
CMouseEvent The user releases the mouse button while over the control.
When an event occurs.
CUIEvent This event occurs when opening the item list.
CUIEvent An event that occurs when the user selects text.
CSelectionEvent ComboBox An event that occurs after the selected item is selected to save the selected value.
oldSelection: {cpr.controls.Item []} Previously Selected Item pre>
newSelection: {cpr.controls.Item []} Item whose selection has changed pre>
Properties
declaring type
|
AccessableUIControl |
type
|
String |
get
|
Returns the keyboard shortcut character.
|
set
|
Keyboard shortcut Sets a single character (letter or number).
The shortcut key is [alt] + [shortcut key] for Windows or [option] + [shortcut key] for Mac.
|
declaring type
|
UIControl |
type
|
Accessbility |
readonly
|
Gets the accessibility-related ARIA properties or gets the context in which they can be specified.
|
type
|
Boolean |
get
|
Returns whether the entire data in the edit area is selected when it is focused.
|
set
|
Sets whether to select all the data in the edit area when it is in focus.
|
type
|
Boolean |
get
|
Returns whether the focus moves to the next control when an item is selected in the list.
|
set
|
Sets whether to move the focus to the next control when an item is selected in the list.
|
type
|
String |
get
|
Returns an image of button.
|
set
|
Sets the image of the button.
|
type
|
String |
get
|
Returns the delimiter when specifying or retrieving multiple selected values.
|
set
|
Sets the delimiter when specifying or importing multiple selected values.
|
type
|
#expression |
get
|
Returns the Expression of the text shown on the screen.
|
set
|
Set the expression of the text shown on the screen.
The values provided for Expression are label and value.
control.displayExp = 'label+"["+value+"]"'
|
type
|
String |
readonly
|
Gets the value of the HTML Element shown in the input.
|
declaring type
|
Control |
type
|
Boolean |
readonly
|
Returns whether the control should be removed.
|
type
|
"list" | "tree" |
get
|
Returns the drop-down list type setting value.
|
set
|
Set the drop-down list type.
|
declaring type
|
UIControl |
type
|
Boolean |
readonly
|
Returns whether the value can be changed by user action.
UIControl (Output, etc.) that does not allow input returns false.
In the case of an inputtable UIControl, returns true if the binding context in which the value is bound is valid.
Otherwise, it returns false even if it is an inputtable UIControl.
Accordion/Button/Group/Dialog/EmbeddedApp/EmbeddedPage/Grid/HTMLObject/Image/MDIFolder/Menu/
NavigationBar/Notifier/Output/Progress/TabFolder/Shell/FileUpload
In the case of the above control, editable is always false.
|
declaring type
|
EnableUIControl |
type
|
Boolean |
get
|
Returns whether the control is enabled.
|
set
|
Sets whether to activate the control.
|
type
|
#expression |
get
|
Returns the item's enabled expression value.
|
set
|
You can set the item's enabled to the column of the dataset bound to the item or the value of label, value.
ex) label! = 'label1'
|
type
|
String |
get
|
Returns the value to replace with the replacement value.
|
set
|
Set the value to be replaced with an alternate value.
|
declaring type
|
UIControl |
type
|
String |
get
|
Returns the logical field name of the control.
|
set
|
Sets the logical field name of the control.
|
type
|
#expression<(item: cpr.controls.Item)=>Boolean> |
get
|
Returns the value of the expression that filters the item.
|
set
|
Sets the expression to filter items.
|
type
|
Boolean |
get
|
Returns whether the width of the open list is fixed to the combobox width.
|
set
|
Sets whether the width of the list to be opened is fixed to the width of the combo box.
|
declaring type
|
UIControl |
type
|
Boolean |
readonly
|
Returns whether the control is focusable.
|
declaring type
|
UIControl |
type
|
Boolean |
readonly
|
Returns whether the control has focus.
|
type
|
Boolean |
get
|
Returns whether to show or hide the Listbox button.
|
set
|
Listbox Sets whether to show or hide the button.
|
declaring type
|
Control |
type
|
String |
readonly
|
Returns the ID of the control.
|
type
|
TreeItemSetConfig |
readonly
|
ItemSet Returns an object with the column name information of the dataset you set.
|
type
|
Number |
get
|
Returns the value of the maximum number of list items.
|
set
|
Set the maximum number of items displayed. The default value is '0', which is displayed at the height set in the listbox.
Items are displayed based on the height of the non-newline item.
|
type
|
Boolean |
get
|
Returns whether the item is multi-selected.
|
set
|
Sets whether to select multiple items.
|
declaring type
|
UIControl |
type
|
String |
get
|
Returns the name of the control.
|
set
|
Sets the name of the control.
|
type
|
String |
get
|
Returns a text (hint) describing the expected value of the InputBox.
|
set
|
Sets a text (hint) that describes the expected value of the InputBox.
|
type
|
Boolean |
get
|
Returns whether to prevent input through the inputbox.
|
set
|
Set whether to prevent input through inputbox.
[true]: Prevents keyboard input and operates as a button.
[false]: Keyboard input is possible.
|
declaring type
|
EnableUIControl |
type
|
Boolean |
get
|
Returns whether a non-modifiable read-only mode is in effect.
|
set
|
Sets whether to enable read-only mode, which can not be modified.
|
type
|
Number |
get
|
Returns the index position where the selection is shown when the popup is opened.
|
set
|
Sets the index position where the selection is displayed when the popup is opened. The default value is '0', which is displayed first.
|
type
|
Boolean |
get
|
Returns the value of whether to display the item's icon.
|
set
|
Sets whether to display the item's icon.
|
type
|
ComboBox$Styler |
readonly
|
Returns the style settings of the control.
In case of style changes, only the corresponding control is updated.
Propagation from style changes does not occur.
|
declaring type
|
AccessableUIControl |
type
|
Number |
get
|
Returns the control focus sequence using the Tab Key.
This property controls the tabindex in HTML.
|
set
|
Set the control focus order using Tab Key.
This property controls the tabindex in HTML.
|
type
|
String |
readonly
|
Returns the text displayed on the screen.
|
declaring type
|
VisibleUIControl |
type
|
String |
get
|
Returns a description of the control
It works when mouse over.
|
set
|
Set a description for the control.
It works when mouse over.
|
type
|
Number |
get
|
Returns the depth value that automatically opens an item.
|
set
|
Specifies the depth value for automatically opening items in the treelist.
Default is 0. A value of -1 is unlimited. If an item is initially opened due to this attribute, it will not be affected the next time.
|
declaring type
|
Control |
type
|
ControlType |
readonly
|
Returns the signature string of the Control's unique Type that can distinguish the Control.
Please refer to ControlType for available constant values.
For UDC controls, each unique type name is returned. Example: udc.MyUDC
|
type
|
Boolean |
get
|
Returns whether to change to an alternate value if it is an invalid value.
|
set
|
Sets whether to change to an alternate value if it is an invalid value.
|
declaring type
|
Control |
type
|
String |
readonly
|
Returns the unique ID of the control.
|
type
|
String |
get
|
Returns the value of the control.
|
set
|
Sets the value of the control.
|
type
|
String[] |
get
|
Returns an array of values stored in the control when multiple selections are made.
|
set
|
Sets the array of values stored in the control when multiple selection is made.
|
declaring type
|
VisibleUIControl |
type
|
Boolean |
get
|
Returns the style property for controlling css visibility.
|
set
|
Sets the style property to control css visibility.
|
type
|
Number |
get
|
Returns the number of rows to scroll at a time with the wheel.
|
set
|
Sets the number of rows to scroll at a time with the wheel.
|
Methods
Add listeners by EventType to the control.
Add a listener to the control to handle when a specific event occurs.
var button = new cpr.controls.Button("btn01");
button.addEventListener("click", function(e) {
// event code...
});
name |
type |
description |
type
|
String |
|
listener
|
(e: cpr.events.CEvent)=>Void |
|
Add a listener to the control that will run only once per EventType.
Add a listener to the control to handle when a specific event occurs.
The added listener is automatically deleted after running once.
Since the object of the added listener is changed, when the listener is deleted
It is an object returned after calling addEventListenerOnce and can be deleted.
var button = new cpr.controls.Button("btn01");
button.addEventListenerOnce("click", function(e) {
// event code...
});
name |
type |
description |
type
|
String |
|
listener
|
(e: cpr.events.CEvent)=>Void |
|
return
|
(e: cpr.events.CEvent)=>Void |
The modified Listener object. |
Add items.
Value and label such as combo box, list, radio button, and check box group are cpr.controls.Item.
Items such as trees, linked listboxes, and linked comboboxes are cpr.controls.TreeItem.
Items such as menus and navigation bars are cpr.controls.MenuItem.
//combobox,list,radiobutton,checkboxgroup
control.addItem(new cpr.controls.Item("label","value"));
//tree,linkedcombobox,linkedlistbox
control.addItem(new cpr.controls.TreeItem("label","value","parentValue"));
//menu,navigationbar
control.addItem(new cpr.controls.MenuItem("label","value","parentValue"));
name |
type |
description |
item
|
Item |
Item information. |
Bind that property.
name |
type |
description |
name
|
String |
|
Removes focus from the control.
Removes the filter for the item.
Deselect all selected items.
name |
type |
description |
emitEventoptional
|
Boolean |
defaulttrue
|
Whether to fire an event (before-selection-change, selection-change). |
Close the list of combo boxes.
name |
type |
description |
emitEventoptional
|
Boolean |
defaulttrue
|
Whether to trigger the close event |
Determines whether to run the Control's Default Event Handler depending on the state of the Control.
name |
type |
description |
e
|
CEvent |
event |
return
|
Boolean |
Whether the control's event handler is running. |
Remove the item corresponding to the index.
name |
type |
description |
index
|
Number |
Item index |
Remove the item.
name |
type |
description |
item
|
Item |
item |
Removes the item corresponding to value.
name |
type |
description |
value
|
String |
The value of the item |
Forwards specific events.
name |
type |
description |
e
|
CEvent |
|
return
|
Boolean |
Whether to continue processing the default action after propagating the event. |
Removes the objects that the control contains.
Find the first item that meets the criteria.
control.findItem ({value: "001"});
control.findItem ({label: "Seoul"});
control.findItem ({value: "001", label: "Seoul"});
code> pre>
name |
type |
description |
condition
|
{
label?: String,
value?: String,
icon?: String,
tooltip?: String,
parentValue?: String,
parentItem?: cpr.controls.TreeItem,
depth?: Number
} |
Condition to find item. |
return
|
Item |
The first item that meets the conditions. |
Find all items that match your criteria.
control.findItems ({label: "Seoul"});
code> pre>
name |
type |
description |
condition
|
{
label?: String,
value?: String,
icon?: String,
tooltip?: String,
parentValue?: String,
parentItem?: cpr.controls.TreeItem,
depth?: Number
} |
Condition to find item. |
return
|
Item[] |
An array of all items that meet the condition. |
Find the parent control.
If includeSelf is true, the parent including the self is found.
name |
type |
description |
predicate
|
(c: cpr.controls.UIControl)=>Boolean |
|
includeSelfoptional
|
Boolean |
defaultfalse
|
Whether you include yourself. |
Assigns focus to the control.
name |
type |
description |
forwardoptional
|
Boolean |
defaulttrue
|
|
Moves focus to the next control.
If there are multiple structural elements that have focus inside a control, focus may transition to the next element.
Moves focus to the previous control.
If there are multiple structural elements that have focus inside a control, focus may transfer to the previous element.
Gets the bounds value of the control relative to the browser's view port.
If the control is not drawn on the screen, an object with all values of 0 is returned.
return
|
Rectangle |
About the position and size of controls in the HTML DOM |
Gets the bounds value of the control relative to the browser's view port.
If the control is not drawn on the screen, an object with all values of 0 is returned.
name |
type |
description |
includeWrap
|
Boolean |
If this value is true, the layout of the parent group gets the area of the node surrounding this control. If false, only get the area of the control node. |
return
|
Rectangle |
About the position and size of controls in the HTML DOM |
Gets the bounds value of the control relative to the browser's view port.
If the control is not drawn on the screen, an object with all values 0 is returned.
name |
type |
description |
options
|
{
includeWrap?: Boolean,
scaled?: Boolean
} |
|
Returns the App to which the control belongs.
Returns the bind context.
Returns the bind property information for the control.
name |
type |
description |
name
|
String |
|
Returns the index of the dataset as an item.
name |
type |
description |
item
|
Item |
|
Returns the index of the dataset as the value of the item.
name |
type |
description |
value
|
String |
|
Returns the set filter expression value.
return
|
#expression<(item: cpr.controls.Item)=>Boolean> |
|
Returns all custom DOM DATA attribute names.
return
|
String[] |
An array of all custom DOM DATA attribute names. |
Returns the Index of the item
For nonexistent items, returns -1.
name |
type |
description |
item
|
Item |
Item information. |
return
|
Number |
Index of corresponding item. |
Gets the index corresponding to the item's value.
name |
type |
description |
value
|
String |
The value of the item |
return
|
Number |
The index of the corresponding item. |
Returns the item corresponding to Index.
name |
type |
description |
index
|
Number |
The index of the item. |
return
|
Item |
Corresponding item. |
Returns the item corresponding to value.
name |
type |
description |
value
|
String |
The value of the item. |
return
|
Item |
Corresponding item. |
Returns the number of items.
return
|
Number |
Number of items. |
Returns whether an item is active.
name |
type |
description |
item
|
Item |
item. |
return
|
Boolean |
Whether the item is active. |
Returns the items.
Gets the filtered List if Filter is applied.
return
|
Item[] |
An array of items. |
deprecatedIt is not used because duplicate values are not allowed. Please use getItemByValue.
Returns a list of items corresponding to value.
name |
type |
description |
value
|
String |
The value of the item. |
return
|
Item[] |
An array of corresponding items. |
Returns the control to be moved by Tab Key or by the autoskip property.
The area being displayed is obtained based on the parent container to which it belongs.
name |
type |
description |
includeWrapoptional
|
Boolean |
defaultfalse
|
If this value is true, the layout of the parent group gets the area of the node surrounding this control. If false, only get the area of the control node. |
Shift + Tab Returns the focus to be moved through the key.
Get the index of the dataset of the selected item. Returns -1 if it is not an item in the dataset.
Get the index of the selected item.
Returns the selected items.
return
|
Item[] |
An array of selected items. |
Returns the first data in the selected list data array.
return
|
Item |
The first selected data. |
Returns the last data in the selected list data array.
return
|
Item |
Last selected data. |
Returns all custom attribute names.
return
|
String[] |
An array of all custom attribute names. |
Gets the closest parent UI control.
Unlike getParent(), it finds nearby parent controls, including external apps.
Specifies custom DOM properties.
name |
type |
description |
key
|
String |
The attribute name to assign |
value
|
String |
The attribute value to specify. |
Returns a custom DOM property.
name |
type |
description |
key
|
String |
The attribute name to get. |
return
|
String |
Custom properties. |
Specify multiple custom DOM properties at once.
name |
type |
description |
values
|
{[key:string]: String} |
A JSON object containing custom attribute keys/values. |
Get all custom DOM properties in the form of a map.
return
|
{[key:string]: String} |
|
Insert the item after the reference item.
name |
type |
description |
item
|
Item |
The item you want to insert. |
offset
|
Item |
Item to be standardized. |
Insert the item before the reference item.
name |
type |
description |
item
|
Item |
The item you want to insert. |
offset
|
Item |
Item to be standardized. |
Returns whether the queried property is bindable and the binding has been configured to obtain a valid value.
Even if no binding is configured and a simple value is specified, it is treated as configured so that a valid value is obtained.
For example, binding to a row index that does not exist in the DataSet is an invalid binding.
name |
type |
description |
name
|
String |
|
Make sure it is a bindable property.
name |
type |
description |
name
|
String |
|
return
|
Boolean |
Confirmation. |
Returns whether the control is floating through an app instance or a specific container.
Returns whether the list of combo boxes is open.
Returns whether the item corresponding to the index is selected.
name |
type |
description |
index
|
Number |
Item index |
return
|
Boolean |
Whether to select the item at the index. |
Returns whether the applicable item is selected.
name |
type |
description |
item
|
Item |
item |
return
|
Boolean |
Whether or not the item is selected. |
Returns whether the item corresponding to value is selected.
name |
type |
description |
value
|
String |
The value of the item. |
return
|
Boolean |
Whether or not the item is selected. |
Returns the status that the screen is showing. Returns false if the visible state of all parents including itself is false.
Open the list of combo boxes.
name |
type |
description |
emitEventoptional
|
Boolean |
defaulttrue
|
Whether to trigger open event |
Sets the value of the control.
name |
type |
description |
value
|
String |
The value of the control. |
Sets the array of values stored in the control when multiple selection is made.
name |
type |
description |
values
|
String[] |
An array of values to be stored in the control. |
Removes all event listeners for the control.
Delete all custom DOM DATA attributes.
Delete all custom attributes.
Remove Listener for each EventType in the control.
control.removeEventListener ('click', listener); code> pre>
name |
type |
description |
type
|
String |
Event type. |
listener
|
(e: cpr.events.CEvent)=>Void |
Event listeners. |
Remove all EventType listeners from the control.
control.removeEventListeners ('click'); code> pre>
name |
type |
description |
type
|
String |
Event type. |
Removes the user-defined DOM DATA attribute for a specific attribute name.
name |
type |
description |
key
|
String |
The custom DOM DATA attribute name to remove. |
If an item corresponding to the index is selected, deselect it.
name |
type |
description |
index
|
Number |
Index of items to deselect |
emitEventoptional
|
Boolean |
Whether to fire an event (before-selection-change, selection-change). |
If the corresponding item is selected, deselect it.
name |
type |
description |
item
|
Item |
Item to deselect |
emitEventoptional
|
Boolean |
Whether to fire an event (before-selection-change, selection-change). |
If an item corresponding to value is selected, deselect the item.
name |
type |
description |
value
|
String |
The value of the item. |
emitEventoptional
|
Boolean |
defaulttrue
|
Whether to fire an event (before-selection-change, selection-change). |
Removes user-defined attributes for a specific attribute name.
name |
type |
description |
key
|
String |
The custom attribute name to remove. |
Select the item corresponding to the index.
The value of the selected item is assigned as the value of the control.
control.selectItem (0);
code> pre>
name |
type |
description |
index
|
Number |
Index of the item to be selected. |
emitEventoptional
|
Boolean |
Whether to fire an event (before-selection-change, selection-change). |
Select the applicable item.
The value of the selected item is assigned as the value of the control.
control.selectItem (item);
code> pre>
name |
type |
description |
item
|
Item |
The item you want to select. |
emitEventoptional
|
Boolean |
Whether to fire an event (before-selection-change, selection-change). |
Select the item corresponding to the label.
The value of the selected item is assigned as the value of the control.
control.selectItemByLabel ("label1");
code> pre>
name |
type |
description |
label
|
String |
The label of the item. |
emitEventoptional
|
Boolean |
defaulttrue
|
Whether to fire an event (before-selection-change, selection-change). |
Select the item corresponding to value.
The value of the selected item is assigned as the value of the control.
control.selectItemByValue ("value1");
code> pre>
name |
type |
description |
value
|
String |
The value of the item. |
emitEventoptional
|
Boolean |
defaulttrue
|
Whether to fire an event (before-selection-change, selection-change). |
Select items corresponding to the index array.
Deselect the previously selected items and select the items.
name |
type |
description |
indices
|
Number[] |
Index array of items to select |
emitEventoptional
|
Boolean |
Whether to fire an event (before-selection-change, selection-change). |
Select those items.
Deselects previously selected items and selects them.
name |
type |
description |
items
|
Item[] |
Array of items to select |
emitEventoptional
|
Boolean |
Whether to fire an event (before-selection-change, selection-change). |
Sets the bind context.
container.setBindContext({dataControl:grid.dataSet,rowIndex:rowIndex})
Use expressions in the list of items to specify filters.
control.setFilter ("value == 'value1'"); code> pre>
name |
type |
description |
condition
|
#expression<(item: cpr.controls.Item)=>Boolean> |
Filter conditions. |
Set whether to activate specific items.
name |
type |
description |
item
|
Item |
item. |
enabled
|
Boolean |
Whether to activate. |
Specify the DataSet of the item.
Dataset1.parsedata ({{
Of
Columns: [
{Datatype: "String", name: "Dataset_value"},
{Datatype: "String", name: "dataset_label"},
],
Of
});
Control.SetitemSet (Dataset1, {Value: "Dataset_value", Label: "Dataset_label"})
Set up a list of items.
name |
type |
description |
items
|
Item[] |
An array of items. |
Sets the control to be moved by Tab Key or by the autoskip property.
name |
type |
description |
nextControl
|
UIControl |
control. |
Shift + Tab Set the focus to be moved through the key.
name |
type |
description |
prevControl
|
UIControl |
control. |
Unbind that property.
name |
type |
description |
name
|
String |
|
Specifies custom properties.
name |
type |
description |
key
|
String |
The attribute name to assign |
value
|
String |
The attribute value to specify. |
Returns a user-defined property.
name |
type |
description |
key
|
String |
The attribute name to get. |
return
|
String |
Custom properties. |
Specify multiple custom properties at once.
name |
type |
description |
values
|
{[key:string]: String} |
A JSON object containing custom attribute keys/values. |
Get all custom properties in the form of a map.
return
|
{[key:string]: String} |
|
Specifies custom data. Unlike user-defined attributes, you can use arbitrary types in addition to strings.
When the control is dispose, all custom data is removed.
name |
type |
description |
key
|
String |
The key of the data to be specified. |
value
|
Object |
Data to specify. |
get custom data
name |
type |
description |
key
|
String |
The key of the data to get. |
Specifies multiple user-defined data.
name |
type |
description |
override
|
{[key:string]: Object} |
A JSON object containing user-defined data. |
Get all your custom data.
return
|
{[key:string]: Object} |
|
Returns a user-defined property.
return
|
Object |
Custom properties. |