Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

SelectSimilar assistance

3 REPLIES 3
Reply
Message 1 of 4
HullDrafter
320 Views, 3 Replies

SelectSimilar assistance

Yes, I know, I am still doing small LISP commands.

 

I am trying to help my new associates in the cleanup of their drawings.

 

One of my co-workers is using Selectsimilar command to clean up drawings.

I was trying to put together a routine to clean up his drawings. I tried to put togerther this routine, but it doesn't want to work.

 

(defun c:JJE () ;begin JJE Erase Similar
(command "_selectsimilar" pause "" "erase" "")
(princ)
)

 

Also tried 

 

(defun c:JJE () ;begin JJE Erase Similar
(command "_selectsimilar" pause "")

(command "erase" "")
(princ)
)

 

Any suggestions to make this work?

HD

3 REPLIES 3
Message 2 of 4

try this for single object

 

(command "aecselectsimilar" pause "" "erase")

 try this for selecting multiple objects

 

(command "aecselectsimilar" (ssget) "" "erase")

 

Message 3 of 4
hmsilva
in reply to: HullDrafter

Try

 

(defun c:JJE ();begin JJE Erase Similar
  (command "_.selectsimilar")
  (while (> (getvar 'cmdactive) 0)
    (command pause)
  )
  ;; while
  (command "_.erase")
  (princ)
)

 

HTH

Henrique

EESignature

Message 4 of 4
HullDrafter
in reply to: hmsilva

I will be trying both methods. Thank you for responding so quickly. 

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost