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.

Constrain shapes which are on two sketches and two faces?

DoglikeDoglike Member Posts: 10
Is it possible to set a coincidence, tangent, or other constraint between shapes which are drawn in two different sketches and on two different faces? I think a picture will help:



I want to add a constraint between the two selected points A and B. I'd like A and B to be coincident, but offset by dimension D.
  • Rectangle C is fully constrained.
  • Circle E is fully constrained on Sketch 2. 
  • Rectangle C is extruded up to part.
  • Circle F only has a diameter constraint at the moment and is on Sketch 3.
Surely there must be a way to do this, right? I'm really new to Onshape and I'm assuming I'm just doing this all wrong. My ultimate goal here is to make a loft (remove) from Circle E to Circle F.

Answers

  • NeilCookeNeilCooke Moderator, Onshape Employees Posts: 5,715
    Yes, just edit the later sketch and add a constraint to the earlier sketch. HOWEVER, your loft will fail because it will create non-manifold topology (please search forum for a detailed discussion on this).
    Senior Director, Technical Services, EMEAI
  • DoglikeDoglike Member Posts: 10
    Thanks for answering NeilCooke, but I don't understand. I asked how to add a constraint and your answer sounds to me like, "Easy, just add a constraint." I don't know how to add the constraint to the earlier sketch. That's precisely my question. Can you explain it in a different way? I realize I'm probably misunderstanding something here.

    And yes, I think I understand why the loft will fail. Due to the circle being tangent to the line. Makes for an infinite edge or something, I guess.
  • NeilCookeNeilCooke Moderator, Onshape Employees Posts: 5,715
    Well, basically, when you edit Sketch 3 you can still see the earlier sketches. So, simply add a constraint :)

    Senior Director, Technical Services, EMEAI
  • tim_hess427tim_hess427 Member Posts: 648 ✭✭✭✭
    @Doglike - when you're editing your sketch, constraining items in your sketch to other edges/sketch items works just like any other constraint. 

    Just make sure both sketches are visible, and you can select lines/points from either one and apply your constraints and dimensions as appropriate. 


  • Alex_KempenAlex_Kempen Member Posts: 248 EDU
    Yeah. To add on a bit more, a lot of constraints can be created between sketch and non-sketch entities. (A constraint must always involve at least one sketch entity, however, because otherwise it doesn't really make sense). An omnipresent example of this is anytime you constrain something to the origin of the part studio; the origin is not in your sketch, yet you can still coincident a corner or a point to it. The same is true for any other edge, face, or edge created prior to the sketch in the model history. If a constraint involves an entity which isn't in the sketch, it turns blue. Otherwise, it's white. 

    You can also constrain to entities which don't lie in the same plane as your sketch; in that case, it is akin to constraining to the projection of said entity onto the sketch. Note that this happens automatically, so you don't have to project the entity you wish to constrain to first (via the use tool or some other method). I hope this helps.
    CS Student at UT Dallas
    Alex.Kempen@utdallas.edu
    Check out my FeatureScripts here:



  • dirk_van_der_vaartdirk_van_der_vaart Member Posts: 549 ✭✭✭
    Maybe I don't understand the original question, but here's my go.
    Put everything in 1 base sketch and in the second sketch use the Use command.


    https://cad.onshape.com/documents/fe171be417ace17106a778fc/w/1379815daaf314265faa81f0/e/734a86ec401bccc37d7135a0

  • DoglikeDoglike Member Posts: 10
    Thanks all for the feedback. I think I'm just going to move on from this one. I must be doing something wrong. I'll stumble on a solution eventually. I didn't describe the real crux in my original post. I copied circle E and pasted it onto the opposing face. But Onshape does not "paste in place" as I'd expect. It puts the circle somewhere to the left/above the original circle. I was hoping to use the constraints to align the two sketch shapes left/right/center/top/etc, but this doesn't seem to be supported.

    As an aside, I get there's some issue of Onshape not knowing where to put the circle, but the app has to put it somewhere, so lacking any other precise directions, why not use the same x,y coordinates as the source? Wouldn't that be the best possible guess? Why put it somewhere completely arbitrary? And yes, I've since learned to use Use for this purpose. 
  • tim_hess427tim_hess427 Member Posts: 648 ✭✭✭✭
    @Doglike - sounds like the "coincident" constraint is what you were looking for, maybe. Select the center point of each circle then the coincident constraint if you want them right on top of each other. 

    Then, you could use "equal" for the diameters if that's unconstrained as well. 
  • shawn_crockershawn_crocker Member, OS Professional Posts: 869 PRO
    @Doglike share your document and someone can make a small screen recording demonstrating what the others are explaining
Sign In or Register to comment.