Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.

Ilogic check all sketch under defined on parts

Manuelcamposcosta
Advocate

Ilogic check all sketch under defined on parts

Manuelcamposcosta
Advocate
Advocate

Hi guys,

 

Can somebody help me out making an ilogic to cycle trough all the sketches in part and check if they are fully defined, if they aren't the rule could give me a message box with the sketch name, I would like to run it in external rule.

 

Can somebody help me?

 

Thanks!

Manuel Campos Costa
0 Likes
Reply
Accepted solutions (1)
466 Views
2 Replies
Replies (2)

JelteDeJong
Mentor
Mentor
Accepted solution

try this rule:

Dim doc As PartDocument = ThisDoc.Document
For Each sketch As PlanarSketch In doc.ComponentDefinition.Sketches
    If (Sketch.ConstraintStatus = ConstraintStatusEnum.kUnderConstrainedConstraintStatus) Then
        MsgBox("Following sketch is under constrained: " & Sketch.Name)
    End If
Next

Jelte de Jong
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Blog: hjalte.nl - github.com

Manuelcamposcosta
Advocate
Advocate

Wow, you are awesome! Just perfect, by they you have really nice addons and they are free!! I will try those ShowFullyConstraint - OccurrenceBundler - Button Constructor

 

Show fully constraint is really a must have, I came from solidworks and I miss that feature a lot.

Manuel Campos Costa
0 Likes