AFILL()

Fill an array with a specified value

Syntax

AFILL( <aArray>, <xValue>, [<nStart>], [<nCount>] ) --> aTarget

Arguments

<aArray> Name of array to be filled.

<xValue> Expression to be globally filled in <aArray>

<nStart> Subscript starting position

<nCount> Number of subscript to be filled

Returns

<aTarget> an array pointer.

Description

This function will fill each element of an array named with the value . If specified, denotes the beginning element to be filled and the array elements will continue to be filled for positions. If Not specified, the value of will be 1, and the value of will be the value of LEN(); thus, all subscript positions in the array will be filled with the value of .

This function will work on only a single dimension of . If there are array pointer references within a subscript , those values will be lost, since this function will overwrite those values with new values.

Examples

LOCAL aTest:={Nil,0,1,2}
Afill(aTest,5)

Status

Ready

Compliance

This function is CA Clipper compliant

Files

Library is vm

See Also