Message 1 of 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Using this guy code http://inventortrenches.blogspot.co.il/2013/01/ilogic-delete-all-sick-assembly.html, im deleting sick constraint quickly. (Thank you Curtis) what will be the addition to the code so it works for "sick joints" the same way ?
Thanks
Dim oAssDoc As AssemblyDocument oAssDoc = ThisApplication.ActiveDocument Dim oConstraint As AssemblyConstraint RUSure = MessageBox.Show _ ("Are you sure you want to Delete all sick constraints?", _ "iLogic",MessageBoxButtons.YesNo) If RUSure = vbNo Then Return Else i = 0 For Each oConstraint In oAssDoc.ComponentDefinition.Constraints If oConstraint.HealthStatus <> oConstraint.HealthStatus.kUpToDateHealth And _ oConstraint.HealthStatus <> oConstraint.HealthStatus.kSuppressedHealth Then oConstraint.Delete i = i + 1 End If Next End If MessageBox.Show(" A total of "& i & " constraints were deleted.", "iLogic")
Solved! Go to Solution.