[mapguide-users] Lat Long Display Issue/Bug

Kori Maleski km at pat.ca
Wed Mar 15 15:26:46 EST 2006


Hi Andy,

If I fire XML to the SetSelectionXML function, it selects the parcel, and
zooms to latlong coordinates in the XY projection.

So instead of X 100000 Y 1000000, it says X -122.000 Y 48.00000.  Note the
XYs.  So the map ends up in the far left lower corner of the map.

I am not calling any zoom function when I am doing this.  

...


If I fire the SetSelectionXML function, then the ZoomToView function
followed by a Refresh - it will select and end up in the correct place.

The ZoomToView function in this case is being passed projected coordinates.


Is my SetSelectionXML doing something funky?






Kori Maleski  BSc. 
Senior Technical Consultant
 

 
Suite 400 - 534 17 Ave. SW Calgary, AB CANADA T2S 0B1
TEL 
403.770.1917
 
 
FAX
877.691.9149
 TOL
877.691.9171
www.pat.ca
 

-----Original Message-----
From: Andy Morsell [mailto:amorsell at spatialgis.com] 
Sent: March 15, 2006 1:14 PM
To: users at mapguide.osgeo.org
Subject: RE: [mapguide-users] Lat Long Display Issue/Bug

 I have some similar custom programming, but no coordinate transformation,
and setSelectionXml does not zoom to the selection automatically.  If you
alert your x and y coordinates being passed to ZoomToView, are they
pre-projected or post-projected?  It's odd that you can get to it work when
SetSelectionXml is not involved since the selection does not have a
coordinate element, only elements for the layer and the object (via the
internal feature ID).


Andy Morsell, P.E.
Spatial Integrators, Inc.
http://www.SpatialGIS.com

-----Original Message-----
From: Kori Maleski [mailto:km at pat.ca] 
Sent: Wednesday, March 15, 2006 11:57 AM
To: users at mapguide.osgeo.org
Subject: RE: [mapguide-users] Lat Long Display Issue/Bug

Thanks Alain,

Here is the real bug then:

Map is projected.
Washington State Plane NAD27 North (ft)

Data is geographic WGS 84

I have a ZoomToView function that reads from a point database with LatLong
columns.

I use the MGProjection/Factory etc. to translate these point positions to
the proper projection.

Send the new coordinates to the ZoomToView.

Works like a charm.


Now:

I want to pass my selection in XML to the SetSelectionXML.
I create an MGSelection object querying a LatLong Parcel Layer in the
Projected Map.

Passes it...

It then selects my feature and zooms to a LatLong position on the XY
projected map (somewhere far far away.

So. 2 Questions:

Does the SetSelectionXML function zoom to its selection automatically?

Why is it zooming to latlong coordinates when the map is projected?



I believe this is a serious bug, unless I am out to lunch somehow...





Kori Maleski  BSc. 
Senior Technical Consultant
 

 
Suite 400 - 534 17 Ave. SW Calgary, AB CANADA T2S 0B1 TEL
403.770.1917
 
 
FAX
877.691.9149
 TOL
877.691.9171
www.pat.ca
 

-----Original Message-----
From: Alain Lebatard [mailto:alain.lebatard at autodesk.com]
Sent: March 15, 2006 12:32 PM
To: users at mapguide.osgeo.org
Subject: RE: [mapguide-users] Lat Long Display Issue/Bug

Hi Kori,

This is a bug that only affects the display of the coordinates. The order of
the parameters in the ZoomToView function has always the same meaning,
regardless of the display settings, so do not switch the Lat and Lon values
in the call to this API.

Alain

-----Original Message-----
From: Kori Maleski [mailto:km at pat.ca]
Sent: Wednesday, March 15, 2006 10:05 AM
To: users at mapguide.osgeo.org
Subject: [mapguide-users] Lat Long Display Issue/Bug


Hi All,

I have a map that I am displaying in Washington State Plane NAD27 North
(ft)
projection and the DWF viewer is switching the Lat for Lon in the
coordinate
display.  

Anyone else see this?  Does this mean we have to switch them for the
ZoomToView function as well?

Cheers,



Kori Maleski  BSc. 
Senior Technical Consultant
 

 
Suite 400 - 534 17 Ave. SW Calgary, AB CANADA T2S 0B1
TEL 
403.770.1917
 
 
FAX
877.691.9149
 TOL
877.691.9171
www.pat.ca
 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
For additional commands, e-mail: users-help at mapguide.osgeo.org



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
For additional commands, e-mail: users-help at mapguide.osgeo.org



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
For additional commands, e-mail: users-help at mapguide.osgeo.org





---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
For additional commands, e-mail: users-help at mapguide.osgeo.org






More information about the Mapguide-users mailing list