DocBook|Search
Class Reference
%ZEN.Component.dataListBox
   
Server:basexml
Instance:SOAXML
User:UnknownUser
 
-
  [BASEXML] >  [%ZEN] >  [Component] >  [dataListBox]
Private  Storage  

class %ZEN.Component.dataListBox extends abstractListBox, querySource

This is a listBox that gets its list from an SQL query.
Refer to the %ZEN.Component.querySource class for a description of how to provide data for this component.
The dataListBox control will support both drag and drop. If dragEnabled is true, then the user can drag values from the list box and drop them on other drop-enabled components.
If dropEnabled is true, then values can be dropped onto the list. The value of the list box will be set to the value of the dropped data.

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
9 9


Summary

Properties
%condition %import %includeFiles %page
%resource OnCreateResultSet OnDrawItem OnExecuteResultSet
align aux choiceColumn clientType
columnName composite containerStyle contentType
controlClass controlStyle countRows dataBinding
disabled displayColumns dragEnabled dropEnabled
enclosingClass enclosingStyle error groupByClause
height hidden hint hintClass
hintStyle hzScroll id index
invalid invalidMessage itemCount label
labelClass labelDisabledClass labelStyle listHeight
listWidth maxRows multiColumn name
onafterdrag onbeforedrag onblur onchange
onclick ondblclick ondrag ondrop
onfocus onhide onkeydown onkeypress
onkeyup onmousedown onmouseout onmouseover
onmouseup onrefresh onshow onsubmit
onupdate onvalidate orderByClause originalValue
parameters parent queryClass queryName
readOnly required requiredMessage selectedIndex
showLabel slice sql sqlLookup
tabIndex tableName text title
tuple valign value valueColumn
visible whereClause width window

Methods
%%OIDGet %AddToSaveSet %Attr %BindExport
%ClassIsLatestVersion %ClassName %ConstructClone %CreateResultSet
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %DrawComponentHTML
%DrawHTML %DrawJSStrings %DrawListContents %EnclosingDivId
%Eval %Extends %ForceClientRender %GetDisplayValue
%GetEventHandlers %GetForm %GetParameter %GetXMLName
%IsA %IsModified %MakeId %Name
%New %NormalizeObject %ObjectModified %OnAddToPageAfter
%OnAddToPageBefore %OnCreateResultSet %OnDrawEnclosingDiv %OnDrawObjectProperties
%OnExecuteResultSet %OnObjectSynch %OnZENDeserialize %OriginalNamespace
%PackageName %QuoteValue %QuoteValueL10N %RemoveFromSaveSet
%Self %SerializeObject %SetDefaultValues %SetModified
%ValidateObject XMLDTD XMLExport XMLExportToStream
XMLExportToString XMLNew XMLSchema XMLSchemaNamespace
XMLSchemaType clickItem dblClickItem dragFinishHandler
dragHandler dragNotifyHandler dragStartHandler dropHandler
dropStartHandler executeQuery exposeComponent findElement
fireOnUpdateEvent focus formatValue getDisabled
getDragData getEnclosingDiv getForm getHidden
getHintElement getInvalidReason getItemEl getLabelElement
getOptionCount getOptionText getOptionValue getProperty
getReadOnly getSettings getType getValue
invokeSuper isModified isOfType isValid
lbKeyBlur lbKeyDownHandler lbKeyFocus lbKeyPressHandler
makeId moveToItem normalizeValue onCreate
onDelete onDisplayHandler onEndModalHandler onPopupAction
onRefreshContents onSerialize onStartModalHandler onchangeHandler
onloadHandler onunloadHandler onupdateHandler refreshContents
render renderContents renderSVG select
selectItem setDisabled setHidden setOverlayMode
setProperty setReadOnly setValue startProgressBar
stopProgressBar sysName unformatValue validationHandler


Properties

• property OnDrawItem as %ZEN.Datatype.delegator(FORMALSPEC="pRS:%SQL.StatementResult,pValue:%String,pText:%String",RETURNTYPE="%String");
(optional) Name of Server-side callback method that is called for each item in the list before it is displayed. This callback is passed the logical and display value for the current item. It returns the HTML that is to be displayed within the cell for the given item.
This must be the name of a server-only method in the page class that contains this table pane.
• property choiceColumn as %ZEN.Datatype.integer(MINVAL=1,ZENSETTING=0) [ InitialExpression = 2 ];
If there are multiple data columns displayed within the data list this is the column number (1-based) of the column that will provide the display value for this control.
If this value is greater than the number of columns in the query then the second column will be used.
• property contentType as %ZEN.Datatype.string(VALUELIST=",text,html") [ InitialExpression = "text" ];
Indicates how display values should be rendered:
If contentType is "text" (the default) then the display values will be HTML-escaped before being rendered.
If contentType is "html" then the display values will not be HTML-escaped before being rendered. Use this when your display values contain HTML markup that you do not want escaped.
• property displayColumns as %ZEN.Datatype.csv(ZENSETTING=0);
If there are multiple data columns displayed in the data list, this optional property defines a comma-delimited list of the column numbers of the column that should be displayed.
• property itemCount as %ZEN.Datatype.integer(XMLPROJECTION="none");
Number of options within the list.
This is calculated when the query for this component is run.
• property multiColumn as %ZEN.Datatype.boolean [ InitialExpression = 1 ];
If true (the default), then display multiple columns in the data list if the result set contains more than 2 columns.
• property parameters as list of %ZEN.Auxiliary.parameter(XMLNAME="parameter",XMLPROJECTION="ELEMENT");
User-defined list of query parameters.
These values are passed on to the user callback function that provides the query for this component in order to provide values for any run-time query parameters.
• property sqlLookup as %ZEN.Datatype.sql;
(optional) SQL statement that, given a value, finds a display value. If present, this is used to find the initial display value for cases where the logical and display values are different.
• property valueColumn as %ZEN.Datatype.integer(MINVAL=1,ZENSETTING=0) [ InitialExpression = 1 ];
If there are multiple data columns displayed in the data list this is the column number (1-based) of the column that will provide the logical value for this control.
If this value is greater than the number of columns in the query then the first column will be used.

Methods

• method %DrawListContents()
Server-side method to provide contents of the list box.
• method %GetDisplayValue(pValue As %String) as %String
Lookup up the display value for the combobox given a logical value.
This is called when the control is initially drawn. A logical value of "", must have a display value of "".
• method %SetDefaultValues()
This method fills in reasonable default values for this control. Used by tools (such as Control Tester) to dynamically create controls.
• method executeQuery() [ Language = javascript ]
Execute the server-side associated with this dataListBox.
The query is executed asynchronously, so results may not be available immediately.
• method getOptionCount() [ Language = javascript ]
Return number of items in list.
• method getOptionText(idx) [ Language = javascript ]
Return the display text for the given item (0-based) in the list.
• method getOptionValue(idx) [ Language = javascript ]
Return the logical value of the given item (0-based) in the list.
• method setProperty(property, value, value2) [ Language = javascript ]
Set the value of a named property.
Assume that subclasses that simply wrap HTML controls have named the control 'control' or else have overridden this method.