vlax-invoke-method
 
 
 

Calls the specified ActiveX method

(vlax-invoke-method obj method arg [arg...])

This function was known as vlax-invoke prior to AutoCAD 2000.

Arguments

obj

A VLA-object.

method

A symbol or string naming the method to be called.

arg

Argument to be passed to the method called. No argument type checking is performed.

Return Values

Depends on the method invoked.

Examples

The following example uses the AddCircle method to draw a circle in the current AutoCAD drawing.

The first argument to AddCircle specifies the location of the center of the circle. The method requires the center to be specified as a variant containing a three-element array of doubles. You can use vlax-3d-point to convert an AutoLISP point list to the required variant data type:

_$ (setq circCenter (vlax-3d-point
'(3.0 3.0 0.0)))
#<variant 8197 ...>

Now use vlax-invoke-method to draw a circle with the AddCircle method:

_$ (setq mycircle (vlax-invoke-method
mspace 'AddCircle circCenter 3.0))
#<VLA-OBJECT IAcadCircle 00bfd6e4>
See Also