This documentation was styled with a demo skin from the Premium Pack 4 add-on for Help & Manual. The contents of the skin are encrypted and not configurable. You can only publish HM projects with this skin. You cannot edit it or change it.
This version is copyright and may only be used for local testing purposes. It may not be distributed.
Please purchase the full version of the Premium Pack to get the configurable skins and remove this notice. The package will also include the Toolbox configuration utility for Premium Pack skins.
Description
Extract from MainArray all elements corresponding to ComparisonTest filling DestinationArray with elements found.
Syntax
nRec = ARRAY EXTRACT MainArray, [COLLATE UCASE,] {StartsWith | EndsWith | Contains} ComparisonStringExpression InTo DestinationArray
Syntax for array of pointer to heap allocated memory areas: each element of MainArray MUST be a DWORD pointer to some memory allocated with HEAP* functions.
nRec = ARRAY EXTRACT MainArray PTR, [COLLATE UCASE,] {StartsWith | EndsWith | Contains} ComparisonStringExpression InTo DestinationArray
Returns
None
Parameters
Name |
Type |
Optional |
Meaning |
MainArray |
Array |
No |
Name of the variable array containing elements to be checked. |
ComparisonStringExpression |
String |
No |
String expression that will be used to compare elements with depending on comparison type: StartsWith, EndsWith, Contains. |
DestinationArray |
Array |
No |
The element index inside the array from which to start assignment. Attention: this array will be automatically free and resized |
Remarks
If COLLATE UCASE will be present, all comparison will take place in upper case format
Restrictions
MainArray and DestinationArray must be dynamic string arrays.
All comparisons are sensible to upper/lower case unless COLLATE UCASE option is present.
See also
LBound, UBound, ARRAY SORT, ARRAY SCAN,
Examples