Fusion API and Scripts
Got a new add-in to share? Need something specialized to be scripted? Ask questions or share what you’ve discovered with the community.
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Keeping Fusion 360 lines via API limited to sketch plane when I want to

Message 1 of 3
571 Views, 2 Replies

Keeping Fusion 360 lines via API limited to sketch plane when I want to

There's a "New Screwdriver" article titled, "Fusion 360 Lines Created Via API Are Not Limited To Sketch Plane". You can find it here: It makes sense that "skipping the unnecessary planes and sketches will generate fewer API objects", but what if I have a particular reason I want to limit the lines to the sketch plane? For instance, I'm generating a plane at angle and want to sketch on that plane or I'm making sketches following a path, and I want to draw lines on each of those sketches. My current solution/workaround is to generate the points starting from an origin plane and then transforming the whole thing to where I want it, but it would be nice to start off from where I want the points in the first place.

Message 2 of 3
in reply to: nickwisc

It appears that when the points are matched up with a sketch, eg sketchXY.sketchCurves.sketchFittedSplines.add(points), the sketch is already treating the coordinates in reference to the sketch's own coordinate system (z in or out of the sketchplane), so it is already doing what I asked for...

Message 3 of 3
in reply to: nickwisc

I want to add a few comments to this.  The article that was originally referenced implies that this is an API only capability.  It's not.  It's possible using the UI to create a sketch in 3 dimensions.  There's a preference setting, as shown below that when enabled will allow you to snap to entities outside of the sketches X-Y plane.  When you click the mouse out in space, the point will be on the X-Y plane of the sketch because Fusion doesn't know where else to put it, but you can snap to existing geometry outside of the X-Y plane.  It's also possible to use the Move command and move sketch geometry out of the sketch X-Y plane.  All sketches in Fusion are 3D, it's just that typically everything remains on the X-Y plane of the sketch.




Brian Ekins
Inventor and Fusion 360 API Expert

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th

Autodesk Design & Make Report