View Single Post
Old 21-03-2011, 19:12
runflacruiser's Avatar
runflacruiser runflacruiser is offline
Senior Member
Join Date: Jun 2009
Location: Pigeon Forge, TN USA
Posts: 811

You must change the offset parameter to absolute and calculate the distance. Here's some old code from Alex.

Sub Macro1()
    Dim s1 As Shape
    Dim s2 As Shape
    Dim cps As CrossPoints
    Dim cp As CrossPoint
    Dim sp1 As SubPath
    Dim sp2 As SubPath
    Set s1 = ActiveLayer.CreateEllipse2(2.36889, 5.814937, 1.166118, -1.166118)
    Set sp1 = s1.Curve.SubPaths(1)
    Set s2 = ActiveLayer.CreateEllipse2(4.284047, 6.402252, 1.464031, -1.464031)
    Set sp2 = s2.Curve.SubPaths(1)
    Set cps = sp1.GetIntersections(sp2, cdrAbsoluteSegmentOffset)
    For Each cp In cps
        sp1.AddNodeAt cp.Offset, cdrAbsoluteSegmentOffset
    Next cp
End Sub
Reply With Quote