Jump to content

Quick Properties


happyunited

Recommended Posts

I have loads of closed polylines and they have all got a different area. There are hundreds.

In the quick select box how would I specify to say select all polylines between a certain area say 100m2 to 500m2? I know to select polylines then area the equal to but what do I put in the box?

 

Thanks

Link to comment
Share on other sites

Quick one:

 

(defun c:qs ( / ss )
 ;; © Lee Mac  ~  02.06.10

 (if (setq ss (ssget "_X" '((0 . "LWPOLYLINE"))))
   (
     (lambda ( i / e area )
       (while (setq e (ssname ss (setq i (1+ i))))
         (setq area (vlax-curve-getArea e))

         (or (< 100. area 500.)
             (ssdel e ss))
       )
     )
     -1
   )
 )

 (sssetfirst nil ss)
 (princ)
)

Link to comment
Share on other sites

Quick one:

 

(defun c:qs ( / ss )
 ;; © Lee Mac  ~  02.06.10

 (if (setq ss (ssget "_X" '((0 . "LWPOLYLINE"))))
   (
     (lambda ( i / e area )
       (while (setq e (ssname ss (setq i (1+ i))))
         (setq area (vlax-curve-getArea e))

         (or (< 100. area 500.)
             (ssdel e ss))
       )
     )
     -1
   )
 )

 (sssetfirst nil ss)
 (princ)
)

 

What do I type in the command line to activate that lisp?

 

Thanks for that

Link to comment
Share on other sites

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...