KRASCHE
&
BYRNE
         ELZED  HOME       NEWS       DOCS       DOWNLOADS       LICENSING       SUPPORT       FAQ       ABOUT  US

What's An Elzed?
Features
Licensing
Downloads
Documentation
Elzed News
    ELZED 
 Documentation 
 The Details 
 API 

lzLinkNumArray

The lzLinkNumArray function establishes the named array within Elzed and associates it with the passed-in host array.

bool lzLinkNumArray(
   char cScope,   // the scope of the linked array
   const char* szVariableName,   // the name of the linked array
   double* dpVariable,   // the associated host array
   long lDimensions,   // the number of array dimensions
   long lDim1,   // first array dimension
   long lDim2,   // second array dimension
   long lDim3,   // third array dimension
   long lDim4,   // fourth array dimension
   long lDim5,   // fifth array dimension
   long lDim6   // sixth array dimension
);

Parameters

cScope
   A character code indicating the scope of the target array. The character code must be one of the following values:

Code
Constant
Meaning
'C'
kCosmicScope
Available in all contexts
'G'
kGlobalScope
Available in current context only


szVariableName
   A null-terminated character string containing the name of the target array. Must be unique within the indicated scope.

dpVariable
   A pointer to the host array to be associated with the target Elzed array.

lDimensions
   A long integer value indicating the total number of array dimensions.

lDim1
   A long integer value indicating the size of the first array dimension.

lDim2
   A long integer value indicating the size of the second array dimension. Pass zero for this parameter if the dimension is not used.

lDim3
   A long integer value indicating the size of the third array dimension. Pass zero for this parameter if the dimension is not used.

lDim4
   A long integer value indicating the size of the fourth array dimension. Pass zero for this parameter if the dimension is not used.

lDim5
   A long integer value indicating the size of the fifth array dimension. Pass zero for this parameter if the dimension is not used.

lDim6
   A long integer value indicating the size of the sixth array dimension. Pass zero for this parameter if the dimension is not used.

Return Value

   Returns TRUE if the array was successfully linked, otherwise FALSE.

Remarks

   VB users must call lzSetInvertArrayIndices with TRUE to successfully access elements in the linked array.

Call lzDeleteVar to break the link (and delete the Elzed portion of the variable).

Since the passed-in host arrays and the Elzed array created by this function share the same location in memory, a change to one causes an immediate and equivalent change to the other. If your program changes an element in the host array, the Elzed array will reflect the change. Likewise, if an expression changes an element in the Elzed array, the corresponding element in the host array will also contain the new value.

It probably goes without saying that the number of dimensions declared must match the number of non-zero dimension parameters. The dimension parameters must be used in order starting with the first one (no skipping).

Versions

   Introduced in Elzed 1.0.0
Modified in Elzed 2.4.0 -- Array name parameter (char*) is now declared const.
   This page describes the version of lzLinkNumArray active in Elzed 2.5.0 (217: 2.5.0)

See Also



  Copyright  ©  MMXXV  by  R R Le Cropane   •   All Rights Reserved   •   Terms of Use   •   Privacy Policy