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.
Converting Variable Type (Angle to a Number)
Erci_Cheung
Member Posts: 2 ✭
New to Onshape and was wondering if there's a way to convert an Angle variable type to a Number? Trying to circular pattern and calculate the number of instances based on the angle variable but it does not like, so is there a way to either convert it or somehow allow me to do some math on it. If I convert the angle to a Number type it works fine but it messes up other things since the variable is no longer an angle. Here is what I have in the Variable Table for Value:
round(#ANGLEPI/180#RADIUS_PITCH)
Answers
Divide by the unit.
So if #Angle is an angular type, doing #Angle/degree will give you a number in degrees.
Experts in Onshape Automation - Custom Features and Integrated Applications