Jump to content

Recommended Posts

Posted

Is there a way of fencing all the ext in a drawing and en masse placing a point at each insertion point?

Posted
Is there a way of fencing all the ext in a drawing and en masse placing a point at each insertion point?

 

Sorry Text

Posted (edited)

a quickie

(defun c:test ()
(vl-load-com)
 (setq ss1 (ssget '((0 . "TEXT,MTEXT")))
   idx 0)
 (repeat (sslength ss1)
   (setq obj-txt (vlax-ename->vla-object (ssname ss1 idx)))
   (entmake
     (list
   (cons 0 "POINT")
   (cons 10 (vlax-get obj-txt 'InsertionPoint))
   )
     )
    (setq idx (1+ idx))
   )
 (princ)
 )

Edited by lpseifert
forgot vl-load-com
Posted

Hi lpseifert, Thanks for the prompt response.

I'm fairly new to script files, lisp routines and codes. How do I use this?

Posted

Tack själv Tiger

 

I get this error when i load and run the lisp routine:

 

; error: no function definition: VLAX-ENAME->VLA-OBJECT

 

Tis Greek to me so any help is more than appreciated.

Posted

above code edited... try it now

Posted

lpseifert,

ta very much for your endeavour and knowledge. The lisp routine works like a dream.

 

This forum rocks:D

Posted

Nothing at all wrong with Larry's example; just showing it without use of VL...

 

(defun c:Test (/ ss)
 (if (setq ss (ssget '((0 . "MTEXT,TEXT"))))
   ((lambda (i / e)
      (while (setq e (ssname ss (setq i (1+ i))))
        (entmake (list '(0 . "POINT") (assoc 10 (entget e))))
      )
    )
     -1
   )
 )
 (princ)
)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...