Author Topic: Divide Polyline?  (Read 2680 times)

0 Members and 1 Guest are viewing this topic.

Atook

  • Swamp Rat
  • Posts: 1029
  • AKA Tim
Divide Polyline?
« on: October 10, 2006, 03:21:14 PM »
I’d like to take a polyline and divide it into equal pieces. Just like the divide command, but in VB(A). When it’s a straight polyline, no problem, as soon as you throw bulges and segments with different slopes it gets more complicated.

Is there an easy way to do this? The Autodesk forums turn up some references to acadx, which has been discontinued, but not much past that.

I’m currently writing in VBA, but would eventually like to port it to VB. I’m writing for r2007.

If there’s a simple way to do this in VB.NET, it might be the trick to get me .NETting.

I believe the hard way will include Brycos post on bulges. And if there’s only a hard way to do it that someone has coded up and would like to share, I’d be more than happy to make use of it. :)
« Last Edit: October 10, 2006, 03:30:09 PM by Atook »

Bryco

  • Water Moccasin
  • Posts: 1883
Re: Divide Polyline?
« Reply #1 on: October 10, 2006, 08:44:44 PM »
Atook the math isn't that hard but you may want to use Curve.cls by Frank Oquendo, I use it in 2006 no problems. You need the Vlax as well. This isn't the same as the discontinued acadx it is 2 classes that allow you to access the math functions exposed in lisp (shhh!)

Glenn R

  • Guest
Re: Divide Polyline?
« Reply #2 on: October 10, 2006, 11:02:10 PM »
...or you could use the curve functions directly available in .NET (Acad that is)
ie getParamAtPoint etc.

Cheers,
Glenn.