<p>Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.</p></p><strong>First time visiting? Here are some places to start:</strong></p><ol style="list-style:inherit;margin-left:25px;"><li>Looking for a certain topic? Check out the <a href="https://forum.onshape.com/categories">categories filter</a> or use Search (upper right).</li><li>Need support? <a href="https://forum.onshape.com/post/question/community-support">Ask a question</a> to our <a href="https://forum.onshape.com/categories/community-support">Community Support</a> category.</li><li>Please submit support tickets for bugs but you can request improvements in the <a href="https://forum.onshape.com/categories/product-feedback">Product Feedback category</a>.</li><li>Be respectful, on topic and if you see a problem, Flag it.</li></ol><p>If you would like to contact our Community Manager personally, feel free to <a href="https://forum.onshape.com/profile/6/LouGallo">send a private message</a> or <a href="mailto:lgallo@onshape.com">an email</a>.
</p>

delete every Nth element in a pattern?

adamohern
adamohern Member, OS Professional Posts: 216 PRO
edited April 2016 in FeatureScript
Are elements "created by" a pattern always listed in order? Would it be reliable to query elements created by a linear pattern and delete every Nth element?

EDIT:

Best solution I can come up with is to do multiple patterns: pattern up to the first skipped element, then pattern that pattern to create the other sections with a distance long enough to leave a gap. Works well in simple cases like this one.

Comments

  • ilya_baran
    ilya_baran Onshape Employees, Developers, HDM Posts: 1,274 image
    By pattern, do you mean opPattern or one of the pattern features?  And by elements do you mean faces or bodies or what?
    Ilya Baran \ VP, Architecture and FeatureScript \ Onshape Inc
  • adamohern
    adamohern Member, OS Professional Posts: 216 PRO
    Well, I guess I'm open to any solution, really. I assumed I would be using opPattern, but I haven't spent much time playing with it. And by elements I guess I mean pattern instances--which may be bodies or features, as applicable based on the pattern type.