Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Reply
Message 1 of 2
Anonymous
481 Views, 1 Reply

Hideobjects

Is there a simple way to hide objects similar to the AutoCAD 2011 hideobjects command?  I have several ways I can use that in a LISP.

 

Thanks

1 REPLY 1
Message 2 of 2
Anonymous
in reply to: Anonymous

You could use something like this:

 

(defun c:hideobj ( / sset)
  (vl-load-com)
  (if (setq sset (ssget))
    (foreach item
      (mapcar
        'vlax-ename->vla-object
        (vl-remove-if
          'listp
          (mapcar 'cadr (ssnamex sset))
        )
      )
      (vla-put-visible item :vlax-false)
    )
    (prompt "\nNothing selected.")
  )
  (princ)
)

 

 

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

Post to forums  

Autodesk Design & Make Report

”Boost