Ask and answer engineering questions

Learn from millions of experts

Missing feed

How to delete sketch constraints at once in Autodesk inventor?

By R TARMARAAJ on 17 Oct 04:08 1 answer 2591 views 0 comments

Delete all sketch constraint in a drawing with usage of iLogic or Macro.

1 answer

  • Carthik
    Carthik almost 4 years ago

    Hi,
    Kindly find the ilogic code below.

    Dim oPartDoc As PartDocument
    Dim oSketch As PlanarSketch

    Dim geoconstraint As GeometricConstraint

    On Error Resume Next

    oPartDoc = ThisApplication.ActiveDocument

    For Each oSketch In oPartDoc.ComponentDefinition.Sketches
    For Each geoconstraint In oSketch.GeometricConstraints
    Call geoconstraint.Delete
    Next geoconstraint

    Next oSketch

    MsgBox ("All constraints deleted!")

    Attachments

    ilogic_sketch_constraint_delete.ipt, 91.5 KB
    Download

Add your answer to: "How to delete sketch constraints at once in Autodesk inventor?"

Save Cancel