Values returned from CentroidX() and CentroidY() are based upon the "current coordinate system".
When you double-click on objects in a map, the coordinates that display are based on the coordinate system of the map. These can both be different from the coordinate system of the table the points live in. The trick is to set the "current coordinate system" to whichever one of these is appropriate for what you're doing. Select Options -> Show MapBasic Window. To set the current coordinate system to the coordinate system of the map window, click on the map window's title bar, then click in the MapBasic Window and type Set Coordsys Window FrontWindow() and hit ENTER. This will make CentroidX() and CentroidY() values match the coordinates you see when you click on the map window. To set the current coordinate system to the coordinate system of the underlying table, type Set Coordsys table MYPOINTTAB in the MapBasic window (where MYPOINTTAB is the name of the table containing the points) and hit ENTER. Hope this helps Spencer -----Original Message----- From: John Eyre [mailto:[EMAIL PROTECTED] Sent: Monday, May 16, 2005 11:11 AM To: MapInfo Subject: MI-L Errors in co-ordinates. I am plotting points on an OS base map. When I click on the points the eastings and nothings are displayed correctly but when I transfer the co-ordinates to a browser using the centroid(x) and centroid(y) functions, there is a systematic error in the returned figures. The error is 100m in both co-ordinates. I would appreciate help from anyone who explain what I'm doing wrong. John Eyre --------------------------------------------------------------------- List hosting provided by Directions Magazine | www.directionsmag.com | To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Message number: 16492
