Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations IDS on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

SW macro to create points along a curve

Status
Not open for further replies.

alxG88

Mechanical
Dec 20, 2013
1
Hi guys, I am a beginner in SW API and I need to create a macro that is able to create evenly spaced points on a curve (line or arch or spline, no matter); in the end my curve could be divided in evenly spaced points. I know that SW is already able to do that but I NEED to do it with a macro. Can you help me?I don't know where I could start from...



Thanks a lot (and sorry for my bad english)
 
Replies continue below

Recommended for you

alxG88,

When you make reference point feature the "d1@refPntFeat" dimension controls the curve location % decimal. You should be able to use this to make a group of N points from [0-1].
Another possibly more involved but easier method is to use hole wizard with a curve pattern option to create your points as ho le internal axes which display as points on plane // parallel to placement plane. I don't use or create many macros but this seems to be a good one to tackle. You should look into how to get the internal axis name from hole wizard feature and how select them for on point ref. My first suggestion will probably work the best, I hope my ideas help.

"It's not the size of the Forum that matters, It's the Quality of the Posts"

Michael Cole
Boston, MA
CSWP, CSWI, CSWTS
Follow me on !w¡#$%
@ TrajPar - @ mcSldWrx2008
= ProE = SolidWorks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor