filtering selection sets

Discussion in 'AutoCAD' started by William Ogle, Aug 25, 2005.

  1. William Ogle

    William Ogle Guest

    I figure i am missing something obvious, but there is something i can't
    figure out when filtering selection sets.

    I often filter a selection set retrieved using a polygon, when i do, it is
    easy to filter, such as this:
    (setq ss1 (ssget "WP" ptlist (list (cons 0 "INSERT") (cons 2 rcount))))

    However, if i prompt a user for a selection set, and want to reuse it over
    and over, usually to count stuff, i can't filter an existing selection set
    using:
    (setq ss1 (ssget ss_bom (list (cons 2 fibspanlabel))))

    I have this workaround, which hasn't caused any problems yet:
    (command "select" ss_bom "")
    (setq ss1 (ssget "p" (list (cons 2 fibspanlabel))))

    I know there is a simpler and more professional way to do this, any one know
    how?

    I know how to step through the sset, look at each entity and ssadd it to a
    second set, but i know acad has an easier way of doing it.


    Thanks, wm
     
    William Ogle, Aug 25, 2005
    #1
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.