The SDL Component Suite is an industry leading collection of components supporting scientific and engineering computing. Please visit the SDL Web site for more information....



Copy2DColTo1DArray


Unit:SDL_openarrays
Class: none
Declaration: function Copy2DColTo1DArray (Src: TDouble2DArray; Col, FirstRow, LastRow: integer; var Dest: TDoubleArray; DestElem): integer;

The function Copy2DColTo1DArray copies the contents of the column Col of the two-dimensional source array Src to the one-dimensional destination array Dest. All rows of the column Col from given indices FirstRow to LastRow will be copied to cell DestElem and the subsequent ones. Indices are 0-based. Setting both parameters FirstRow and LastRow to zero values defaults to the entire column.

The function returns the following error codes:
 0 ... everything is OK
-1 ... Src has size zero size
-2 ... FirstRow and/or LastRow do not constitute a valid range
-3 ... Col is not valid
-4 ... the parameter DestElem is out of range (valid range: 0 to length(Dest)-1)


Last Update: 2023-Feb-06