Show pageOld revisionsBacklinksBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== Extract function ====== ==== Description ==== Extracts a field, value, or subvalue from a dynamic array. ==== Syntax ==== //result// = **Extract**(//array//, //field//, //value//, //subvalue//) ==== Parameters ==== The Extract statement has the following parameters ^Parameter^Description^ |//array//|Specifies the dynamic array that is to be accessed.| |//field//|The field number of the field in array to extract. Values for //value// and //subvalue// must be 0 (zero) to extract the field.| |//value//|The ordinal number of the value to be extracted. The value for //subvalue// must be 0 (zero) to extract //value//. //field// must be greater than 0 (zero).| |//subvalue//|The ordinal number of the subvalue to be extracted. The values of //field// and //value// must be greater than 0 (zero).| \\ Compiled code will run more efficiently when //field// is an integer constant, and //value// and //subvalue// are equal to zero. The Extract function is identical to the angle brackets (< >).| ==== See Also ==== [[angle_brackets_operator|< >]], [[delete_function|Delete()]], [[insert|Insert()]], [[replace|Replace()]], [[remove|Remove statement]], [[bremove|BRemove statement]] ==== Example ==== <code> /* If subvalue 1, of value 2, of field 3, of dynamic array Y is greater than 6, the program will go to next_step. */ If Extract(Y, 3, 2, 1) GT 6 Then GoSub next_step End * Extracts columns 1 to 31 from CASH. For counter = 1 To 31 T = Extract(CASH, counter, 0, 0) Next counter ** ** </code> guides/programming/programmers_reference_manual/extract.txt Last modified: 2024/06/19 20:20by 127.0.0.1