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.
Use a formula as a measurement or derived

I am building this weird thing - and longs story short - I need to calculate the number of objects in a circular pattern in a sketch, from measurements which come from another sketch.
Its super that I can create a "derived" variable from one of the measurements - but the problem is I need to specify the "multplier" field for the circular pattern tool as an integer - so the number I need to enter is:
round(#dia/pi*#space/in)
(The final "in" being used to make it unitless).
This works - but it resolves to the exact VALUE in the field - i.e. it does not change if any of those variables change - and when I go back to edit it - it's just the numeric value that it calculated.
Same goes for if I try to make this number a derived variable.
Any idea how I can do this?
Its super that I can create a "derived" variable from one of the measurements - but the problem is I need to specify the "multplier" field for the circular pattern tool as an integer - so the number I need to enter is:
round(#dia/pi*#space/in)
(The final "in" being used to make it unitless).
This works - but it resolves to the exact VALUE in the field - i.e. it does not change if any of those variables change - and when I go back to edit it - it's just the numeric value that it calculated.
Same goes for if I try to make this number a derived variable.
Any idea how I can do this?
0
Best Answer
-
eric_pesty Member Posts: 2,115 PRO
No, sketch patterns can not be controlled by variables on on shape unfortunately...
The best workaround is to use a feature pattern instead, which can be driven by variables.
If you can't just create an extrude (or whatever feature you want) independently, you can use a sketch to define the first instance and pattern that or you can also create a surface entity of the shape you want and pattern that (you can use it pretty much like a sketch).0
Answers
The best workaround is to use a feature pattern instead, which can be driven by variables.
If you can't just create an extrude (or whatever feature you want) independently, you can use a sketch to define the first instance and pattern that or you can also create a surface entity of the shape you want and pattern that (you can use it pretty much like a sketch).