why follow Error "curve must be in the plane"

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Dim application As Autodesk.Revit.ApplicationServices.Application = document.Application
Dim startPoint As New XYZ(0, 0, 0)
Dim endPoint As New XYZ(10, 10, 0)
Dim geomLine As Line = Line.CreateBound(startPoint, endPoint)
Dim end0 As New XYZ(1, 0, 0)
Dim end1 As New XYZ(10, 10, 10)
Dim pointOnCurve As New XYZ(10, 0, 0)
Dim geomArc As Arc = Arc.Create(end0, end1, pointOnCurve)
Dim origin As New XYZ(0, 0, 0)
Dim normal As New XYZ(1, 1, 0)
Dim geomPlane As Plane = Plane.CreateByNormalAndOrigin(normal, origin)
Dim sketch As SketchPlane = SketchPlane.Create(document, geomPlane)
Dim line__1 As ModelLine = TryCast(document.Create.NewModelCurve(geomLine, sketch), ModelLine)
Dim arc__2 As ModelArc = TryCast(document.Create.NewModelCurve(geomArc, sketch), ModelArc)