vlax-safearray-get-dim (AutoLISP/ActiveX)

Returns the number of dimensions in a safearray object

Supported Platforms: Windows only

Signature

(vlax-safearray-get-dim var)
var

Type: safearray

A variable containing a safearray.

Return Values

Type: Integer or nil

A numeric value 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