Maybe the easiest way would be to create these segments as an array of separate polyline objects, and then combine them into one when you have finished.

r

On Mon, 17 Jan 2005 16:44:45 +0800, David Baker <[EMAIL PROTECTED]> wrote:

I have a MapBasic 4.5 command:

Alter Object TempPolyLine Node Add Position PolylineSections, ObjectInfo(TempPolyLine, OBJ_INFO_NPNTS) + 1 (PointLong, PointLat)

TempPolyLine is my polyline which was originally created with:

        Create Pline Into Variable TempPolyLine 0

PolylineSections is a "SmallInt value (one or larger), identifying one section from a
polyline object".


ObjectInfo(TempPolyLine, OBJ_INFO_NPNTS) + 1 is of course the number of
existing nodes + 1, to refer to my new node number that I am about to create.


PointLat & PointLong are my Latitude & Longitude of the node I want to create.



I am reading in polylines from another file format (Garmin .mp "polish" format). These
polylines have multiple sections, so I want to create the MapInfo polylines with the same
multiple sections.


All works well while PolylineSections is 1, but as soon as I try to add the first node after
changing PolylineSections to 2, I get a MapBasic error:


        "Alter Object Node Add failure"

Am I trying to do this the wrong way? Can I just keep adding points & the new section
will be created automatically, or am I missing some command to inform MapBasic that I
am adding in a new section?


Thanks,

Dave




--------------------------------------------------------------------- List hosting provided by Directions Magazine | www.directionsmag.com | To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Message number: 14872





-- ________________________________________________

Robert Crossley

Agtrix P/L
9 Short St
PO Box 63
New Brighton 2483
Far Southern Queensland
AUSTRALIA

153.549004 E 28.517344 S

P: 02 6680 1309
F: 02 6680 5214
M: 0419 718 642
E: [EMAIL PROTECTED]
W: www.agtrix.com
W: www.wotzhere.com

---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 14873



Reply via email to