|
|
|
|
|
TableSelectCount (Function) In french: TableSelectOccurrence Returns the number of selected elements in a Table or TreeView Table control (especially for a multi-selection control). The number of selected elements can correspond to: - the number of selected rows (current rows onto which the selection bar is displayed).
- the number of selected cells if the controls allows the selection mode by cell. This option can be configured in the "UI" tab of the control description.
- the number of selected columns if the control allows the selection mode by column. This option can be configured in the "UI" tab of the control description.
i is int
NbSelectionne is int
NbSelectionne = TableSelectCount(TABLE_Produit)
FOR i = 1 TO NbSelectionne
Trace("Ligne sélectionnée: " + ...
TABLE_Produit[TableSelect(TABLE_Produit, i)])
END
i is int
NbSelection is int = TableSelectOccurrence(TABLE_MaTable)
FOR i = NbSelection TO 1 STEP -1
TableDelete(TABLE_MaTable, TableSelect(TABLE_MaTable, i))
END
Syntax
<Result> = TableSelectCount(<Table control> [, <Information to return>])
<Result>: Integer - Number of selected rows in the specified control,
- 0 if no row is selected.
This number can be greater than 1 for multi-selection controls.
<Table control>: Control name Name of the control to be used. This control can correspond to: - a Table control.
- a TreeView Table control.
If this parameter corresponds to an empty string (""), the control to which the current event belongs is used. A WLanguage error occurs if this parameter does not correspond to the name of a Table or TreeView Table control. <Information to return>: Integer constant Type of information to return: | | tsCell | <Result> will correspond to the number of selected cells. | tsColumn | <Result> will correspond to the number of selected columns. | tsRow (Default value) | <Result> will correspond to the number of selected rows. |
If this parameter is not specified, the function will return the number of selected rows. Remarks Use conditions TableSelectCount can be used on: - Table or TreeView Table controls based on a data file.
- Table or TreeView Table controls populated programmatically.
- single-selection or multi-selection controls.
 Reminder: Multi-selection is not available for Table fields in "Server" mode.
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|