Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:

  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.

Query external bodies during in context edit of part from assembly.

Jacob_CorderJacob_Corder Member Posts: 7 PRO

Hi.

I am wondering if there is a query that will find bodies while editing in context of an assembly.

Basically, I want to import all assembly components into a part studio to “Shrink Wrap” the model to be shared with internals hidden.

All I am missing is the ability to Query All in context bodies. perhaps qAllInContextBodies 😊!

Thanks, let me know if there is something that may work, or a hint if it’s something in process.

Comments

  • john_mcclaryjohn_mcclary Member, Developers Posts: 2,323 PRO
    FeatureScript is usually limited to just part studios. 

    Tdat being said, you may need to invoke in-context manually and update manually

    Then the beging of your fs could query all bodies and transform copy inplace. Then make a composite part. All in the FS.

    That sound right?
  • Jacob_CorderJacob_Corder Member Posts: 7 PRO
    @john_mcclary
    I figured this was the response I would get, manually doing things is not efficient. This is why we automate stuff correct? 

    the bodies exist in the interface, but grayed out as they actually only exist in the assembly portion. 
    I already have the featurescript written that will copy the bodies, opPattern them using identityTransform. 

    I hope in the future, onshape exposes access to in-context parts. I Suppose the API is capable of doing this, but featurescript is so much easier and faster to work with.

    thanks for your reply. 
  • lanalana Onshape Employees Posts: 495
    You can have your feature accept bodies as a selection and select all bodies of assembly context manually.
Sign In or Register to comment.