vlax-safearray-get-dim

AutoCad AutoLISP Functions

 
vlax-safearray-get-dim
 
 
 

Returns the number of dimensions in a safearray object

(vlax-safearray-get-dim var)

Arguments

var

A variable whose data type is a safearray.

Return Values

An integer identifying the number of dimensions in var. An error occurs if var is not a safearray.

Examples

Set sa-int to a single-dimension safearray with one dimension:

_$ (setq sa-int (vlax-make-safearray
vlax-vbinteger '(1 . 4)))
#<safearray...>

Use vlax-safearray-get-dim to return the number of dimensions in sa-int:

_$ (vlax-safearray-get-dim
sa-int)
1