COUNTA

Returns count of the rows in the table control which contain a decimal value (as opposed to a NULL or an invalid value). The function accepts values only from textbox, label and literal controls. This function is called as <TableControlName>.COUNTA("<ControlName>"). Use a TableControl instance to indicate which TableControl contains the values to be operated on by the function (e.g., Order_DetailsTableControl, ProductsTableControl, CategoriesTableControl).

Syntax

= <TableControlName>.COUNTA(controlName)

Parameters

controlName

It represents the name of the control which contains the values whose count is to be calculated. The controlName should be a string (e.g., “UnitPrice”, “Quantity”, Discount). The values in the control can be an integer (e.g., 37), a decimal value (e.g., 37.48), a character (‘A’), or a string (“IronSpeed”).

Return Type

Decimal

Examples

Example

Returns

= ProductsTableControl.COUNTA(“UnitPrice”)

The number of rows in the “UnitPrice” control which are not null and are decimal values.

= Order_DetailsTableControl.COUNTA("Quantity")

The number of rows in the “Quantity” control which are not null and are decimal values.

= Order_DetailsTableControl.COUNTA("Discount")

The number of rows in the “Discount” control which are not null and are decimal values.