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.
Are there better ways to do these configurations?

I made a configurable #25 chain sprocket, but then also made a chain that wraps around it so I can check for clearance.
If the sprocket has an odd number of teeth, it uses a half-link. If it's even, it doesn't need the half link, but the only way I figured to automatically hide the half link using IF logic, was to extrude something either 0" or extrude normally. if it extrudes 0", the half link breaks and simply doesn't show up. But I don't like seeing red!
Is there a better way to prevent a part in the tree from being shown or created using an odd-even check on the user input variable for sprocket teeth?
https://cad.onshape.com/documents/e72b6c7b258f55661cf2d0ca/w/64769064665850fe560aa3e3/e/f190f9139c3268a01eadb0f6
Comments
Couldn't you figure out even or odd numbers and then just suppress visibiliy of the half vs. full link, depending on odd is true/false?
You could create the link in a separate studio, then derive it when it's an odd number.
Here is how you can check if it's an odd number:
#Tooth_Count % 2
It isn't possible yet, to control feature suppression based on logic unless you are using a custom feature. I made a custom feature specifically for this:
https://forum.onshape.com/discussion/27891/logic-driven-feature-new-custom-feature…
Here is an example for your studio of how you can control the suppression of features with variables / logic or even other features.
You could avoid the yellow and feature tree by creating the link in another studio then using the Logic Driven - Derive.
https://cad.onshape.com/documents/2b7cf8ab89297238b88b5eac/w/347b8f4069bbfa75e26aa33d/e/b574b19bb63f3…
Learn more about the Gospel of Christ ( Here )
CADSharp - We make custom features and integrated Onshape apps! Learn How to FeatureScript Here 🔴
@MichaelPascoe ooh, I'll have to take a look at that. I am using that kind of logic to control control the extrude, but suppression is what I'm looking for. Thx