PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
  • Use conditions
  • Equivalence <Table>.Select
  • Value of selected element
  • Selection at cell level
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Returns the subscript of selected element in the Table or TreeView Table control. This subscript can correspond to:
  • the number of the selected row. The selected row corresponds to the current row on which the selection bar is displayed.
  • Versions 16 and later
    the number of the selected column if the control allows the selection mode by column. This option can be configured in the "GUI" tab of control description.
    New in version 16
    the number of the selected column if the control allows the selection mode by column. This option can be configured in the "GUI" tab of control description.
    the number of the selected column if the control allows the selection mode by column. This option can be configured in the "GUI" tab of control description.
  • Versions 16 and later
    the number of the selected cell if the controls allows the selection mode by cell. This option can be configured in the "GUI" tab of control description.
    New in version 16
    the number of the selected cell if the controls allows the selection mode by cell. This option can be configured in the "GUI" tab of control description.
    the number of the selected cell if the controls allows the selection mode by cell. This option can be configured in the "GUI" tab of control description.
  • Versions 16 and later
    the column number of the selected cell if the controls allows the selection mode by cell. This option can be configured in the "GUI" tab of control description.
    New in version 16
    the column number of the selected cell if the controls allows the selection mode by cell. This option can be configured in the "GUI" tab of control description.
    the column number of the selected cell if the controls allows the selection mode by cell. This option can be configured in the "GUI" tab of control description.
Versions 20 and later
Android This function is now available for Android applications.
iPhone/iPad This function is now available for iPhone/iPad applications.
New in version 20
Android This function is now available for Android applications.
iPhone/iPad This function is now available for iPhone/iPad applications.
Android This function is now available for Android applications.
iPhone/iPad This function is now available for iPhone/iPad applications.
Example
// Subscript of selected row in the "TABLE_Product" control
ResSelect = TABLE_Product.Select()
// Rows selected in a multiselection memory Table control
FOR i = 1 _TO_ TABLE_TABLE1.SelectOccurrence()
Trace("Selected element: " + TABLE_TABLE1.Select(i))
END
 
// Equivalent to:
// i is int
// FOR EACH SELECTED ROW i OF TABLE_TABLE1
// Trace("Selected element: " + TABLE_TABLE1.Select(i-1))
// END
// Delete all selected rows from a Table control
// <Table>.DeleteSelect can also be used
i is int
NbSelection is int
NbSelection = TABLE_MyTable.SelectCount()
FOR i = NbSelection TO 1 STEP -1
TABLE_MyTable.Delete(TABLE_MyTable.Select(i))
END
Syntax
<Result> = <Table control>.Select([<Rank> [, <Information to return>]])
<Result>: Integer
  • Subscript of selected element in the specified Table control,
  • -1 if no element is selected.
<Table control>: Control name
Name of control to use. This control can correspond to:
  • a Table control.
  • a TreeView Table control.
<Rank>: Optional integer
Rank of selection for a multiselection control. If this parameter is not specified, the subscript of first selected row is returned.
For example, to retrieve the first selected element, <Rank> = 1.
To retrieve the second selected element, <Rank> = 2, etc.
<Information to return>: Optional Integer constant
Versions 16 and later
Type of information to return:
tsColumn<Result> will correspond to the number of the selected column.
tsCellColumn<Result> will correspond to the column number for the selected cell.
tsRow
(Default value)
<Result> will correspond to the number of the selected row.
tsCellLine<Result> will correspond to the row number for the selected cell.
If this parameter is not specified, the function will return the number of the selected line.
New in version 16
Type of information to return:
tsColumn<Result> will correspond to the number of the selected column.
tsCellColumn<Result> will correspond to the column number for the selected cell.
tsRow
(Default value)
<Result> will correspond to the number of the selected row.
tsCellLine<Result> will correspond to the row number for the selected cell.
If this parameter is not specified, the function will return the number of the selected line.
Type of information to return:
tsColumn<Result> will correspond to the number of the selected column.
tsCellColumn<Result> will correspond to the column number for the selected cell.
tsRow
(Default value)
<Result> will correspond to the number of the selected row.
tsCellLine<Result> will correspond to the row number for the selected cell.
If this parameter is not specified, the function will return the number of the selected line.
AndroidiPhone/iPad This parameter is not available. The function will return the number of the selected row.
Remarks

Use conditions

<Table>.Select can be used on:
  • a browsing or memory control.
  • a single-selection or multiselection control. For multiselection Table controls, you must use <Table>.Select in a loop to get all the selected rows.
AndroidiPhone/iPad The TreeView Table control is not available.

Equivalence <Table>.Select

The following syntaxes are equivalent:
Subscript is int
Subscript = <Table control>
or
Subscript = <Table control>.Select()

Value of selected element

To retrieve the value of selected element, the syntax is:
Subscript is int
Subscript = <Table control>.Select()
<Element value> = <Table control> [Subscript]
or
<Element value> = <Table control> [<Table control>]
Versions 16 and later
Windows Mobile

Selection at cell level

For a control that is using a "multiple selection" mode for the cells, ..Selected is used to find out whether a cell is selected or to select a cell by programming.
New in version 16
Windows Mobile

Selection at cell level

For a control that is using a "multiple selection" mode for the cells, ..Selected is used to find out whether a cell is selected or to select a cell by programming.
Windows Mobile

Selection at cell level

For a control that is using a "multiple selection" mode for the cells, ..Selected is used to find out whether a cell is selected or to select a cell by programming.
Component : wd240obj.dll
Minimum version required
  • Version 23
This page is also available for…
Comments
Click [Add] to post a comment