AnsweredAssumed Answered

MakeStyledCurves2() method defaults to closed spline with certain sketches

Question asked by Andrew Overby on Dec 9, 2019

Hey everyone, 

 

I am working on a macro that uses the method linked below (same as the Fit Spline tool):

2018 SOLIDWORKS API Help - MakeStyledCurves2 Method (IFeatureManager) 

 

My goal is to create a continuous spline along an open profile. The problem is at certain geometries, the function defaults to creating a closed spline. Is there a way to disable that feature so I can always have it as an open spline? The attached image is essentially what I am after with the API function (disregard the Tolerance field).

 

With this open spline, I am grabbing the end points to append sketch segments. I am also open to different procedures to find these points. I did not have much luck on how to locate the endpoints of an open sketch chain, so that is why I have been trying to make the MakeStyledCurves2 function work properly. If this doesn't work, I am also attempting to use a process where I find all the start & end points for the sketch segments and rule out the points that do not join segments together to find the end points.

 

Any recommendations are appreciated!

 

Thanks in advance,

Andrew

Attachments

Outcomes