Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- 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.
Is it possible to make
Hi,
I'm a beginner in FeatureScript, please tell me is it possible to make a feature which is automatically moving some faces to adjust the height of the body.
It will be much easier if I write an example:
I'm buying material as 50, 60, 70 and 80 mm aluminum billets. I have one standard 3D solid body (50 mm height). I'm adding another body on the upper face and now overall height is for example 74 mm. Now I have to manually move some bottom faces to achieve the 70 mm. Which faces should I move? For example I can change color of these faces to green.
Thanks,
Maciek
Comments
-
Yes this is possible with Featurescript, but it might also be possible with configurations and no code needed. I'm not 100% clear on the intended use-case. Screenshots or an example Onshape document would help.
0 -
Every part is different document, so configurations won't help here.
https://cad.onshape.com/documents/5b978e14ef53de7bc156076a/w/9f9a81154c69f036052af5ab/e/35b33558dea2b11720dfd1f2?renderMode=0&uiState=67eff49847fe9d4e6b568ea2
0 -
I would think a "move face" "up to" (with offset if needed) should do it no?
0 -
in featurescript?
0 -
Try something like this:
opOffsetFace(context, id + "offsetFace1", { "moveFaces" : adjacentFaces, "offsetDistance" : (definition.oppositeDirection ? 1 : -1) * definition.Offset });
RENDERCAD
rendercad.ai - Photorealistic product rendering.
▚▞▚▞▚▞▚▞▚
________________________________________________________________________0


