Hi Daniel,
make sure you loop trough all polygons in a multi-polygons regions.
To access all nodes in a multi-polygons regions, you have to inbed a
loop in an other. look:
For i=1 to ObjectInfo(selection.obj,OBJ_INFO_NPOLYGONS)
For j=1 to ObjectInfo(selection.obj, OBJ_INFO_NPOLYGONS+i)
thisXnode = ObjectNodeX(selection.obj, i, j)
thisYnode = ObjectNodeY(selection.obj, i, j)
Next
Next
To know if there are multi-polygons regions, try this SQL:
Select * from your_table where val(ObjectInfo(obj, 21)) >1 into multipgn
Good luck
-----Message d'origine-----
De: Daniel Mack [mailto:[EMAIL PROTECTED]]
Date: 24 f�vrier, 1999 10:52
�: [EMAIL PROTECTED]
Objet: MI Problem with objectnodeX and objectnodeY functions
I am experiencing what seems to be a bug in MapInfo/MapBasic. I am accessing
the coordinates of region boundaries by getting the total number of
coordinates using the objectInfo function, then accessing each individual
coordinate pair by setting a counter and looping until the total number of
coordinates is reached. This works 90% of the time, but periodically it
craps out saying something like "the coordinate is out of range".
Has anyone experienced a problem like this?
Thanks,
Daniel Mack
Cave Creek Systems
Box 641 Nelson, B.C. V1L 5R4
(250)352-3085
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]