Message 1 of 6
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I am trying to identify dimensions in my Inventor Drawing that have crossing dimension lines or extension lines.
I am getting the dimension line and extension lines with
Dim oFirstDimLine As LineSegment2d = oFirstDimension.DimensionLine
Dim oFirstExtLine1 As LineSegment2d = oFirstDimension.ExtensionLineOne
Dim oFirstExtLine2 As LineSegment2d = oFirstDimension.ExtensionLineTwo
and
Dim oSecondDimLine As LineSegment2d = oSecondDimension.DimensionLine
When attempting to get the intersection, I get no results even though I can see that they are crossing on the drawing.
If oFirstDimLine.IntersectWithCurve(oSecondDimLine) IsNot Nothing And oFirstExtLine1.IntersectWithCurve(oSecondDimLine) IsNot Nothing And oFirstExtLine2.IntersectWithCurve(oSecondDimLine) IsNot Nothing Then
' If the extension lines are crossed, display a message box
MsgBox("Dimension " & oFisrtDimension.Text.Text & " & Dimension " & oSecondDimension.Text.Text & " have crossed extension lines.",,"Crossed")
oSelectSet.Select(oFirstDimension)
oSelectSet.Select(oSecondDimension)
End If
LineSegment2d.IntersectWithCurve takes a curve as input that can be another LineSegment2d so why isn't this working for me?
LineSegment2d.IntersectWithCurve( Curve As Object, [Tolerance] As Double ) As ObjectsEnumerator
Curve | Object | Input object. This can be a Line2d, LineSegment2d, Arc2d, EllipticalArc2d, Circle2d, EllipseFull2d, or a BSplineCurve2d. |
Thank you.
Solved! Go to Solution.