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.

Get all faces of a part

Lee_HeskethLee_Hesketh Member, Developers Posts: 148 ✭✭
Hi, how could I get all the faces of a body? I have got the body I need, I just need to iterate through the faces to find the smallest area and use that in a distance calculation. The body is a simple cuboid.
Thanks
Lee Hesketh
There are 10 types of people in the world. Those who know binary, those who don't and those who didn't expect base 3!

Best Answer

Answers

  • Lee_HeskethLee_Hesketh Member, Developers Posts: 148 ✭✭
    @ilya_baran qSmallest brings a red underline error, it seems that isn't a true query.
    There are 10 types of people in the world. Those who know binary, those who don't and those who didn't expect base 3!
  • ilya_baranilya_baran Onshape Employees, Developers, HDM Posts: 1,173
    It is real: qSmallest but you may need to make sure that your std library version (at the top of the feature studio) is recent (it was introduced towards the end of summer).  Latest version is 477.
    Ilya Baran \ VP, Architecture and FeatureScript \ Onshape Inc
  • Lee_HeskethLee_Hesketh Member, Developers Posts: 148 ✭✭
    Ahh, so do I just change the number? Currently it says 432
    There are 10 types of people in the world. Those who know binary, those who don't and those who didn't expect base 3!
  • ilya_baranilya_baran Onshape Employees, Developers, HDM Posts: 1,173
    That's strange -- qSmallest is in 432.  The number should appear in two places: the first "FeatureScript" line and the import onshape/std/geometry.fs line below -- is the number in the import line also 432.0?
    Ilya Baran \ VP, Architecture and FeatureScript \ Onshape Inc
  • Lee_HeskethLee_Hesketh Member, Developers Posts: 148 ✭✭
    Yes, both say 432 but I changed both to 477 and qSmallest came up and the script you posted works
    There are 10 types of people in the world. Those who know binary, those who don't and those who didn't expect base 3!
Sign In or Register to comment.