(vl-load-com)
(defun c:vin (/ adoc selset pt ml _kpblc-objectidtoobject idx)
(defun _kpblc-objectidtoobject (obj id)
(if (and (> (vl-string-search "x64" (getvar "platform")) 0)
(vlax-method-applicable-p obj 'objectidtoobject32)
) ;_ end of and
(vla-objectidtoobject32 obj id)
(vla-objectidtoobject obj id)
) ;_ end of if
) ;_ end of defun
(if
(and (= (type (setq selset (vl-catch-all-apply
(function
(lambda ()
(ssget "_+.:L:S" '((0 . "*TEXT")))
) ;_ end of lambda
) ;_ end of function
) ;_ end of vl-catch-all-apply
) ;_ end of setq
) ;_ end of type
'pickset
) ;_ end of =
(setq selset (vlax-ename->vla-object (ssname selset 0)))
(= (type
(setq pt (vl-catch-all-apply
(function (lambda () (getpoint "\nТочка, от которой будет строиться мультивыноска <Отмена> : ")))
) ;_ end of vl-catch-all-apply
) ;_ end of setq
) ;_ end of type
'list
) ;_ end of =
pt
) ;_ end of and
(progn
(vla-startundomark (setq adoc (vla-get-activedocument (vlax-get-acad-object))))
(setq
ml (vla-addmleader (_kpblc-objectidtoobject adoc (vla-get-ownerid selset))
(vlax-make-variant
(vlax-safearray-fill
(vlax-make-safearray vlax-vbdouble
'(0 . 5)
) ;_ end of vlax-make-safearray
(append pt (vlax-safearray->list (vlax-variant-value (vla-get-insertionpoint selset))))
) ;_ end of vlax-safearray-fill
) ;_ end of vlax-make-variant
1
) ;_ end of vla-addmleader
) ;_ end of setq
(vla-put-contenttype ml 2)
(vla-put-textstring ml (vla-get-textstring selset))
(vla-erase selset)
(vla-endundomark adoc)
) ;_ end of progn
) ;_ end of if
(princ)
) ;_ end of defun