With Proj4Projection, you can go from one projection to another and vice versa. First, you need to know how you set the internal and the external projection. You have to think logically about your internal and external projections and use the ConvertToInternalProjection or the ConvertToExternalProjection to go one way or another.
//Sets the projection parameters to go from Geodetic (EPSG 4326) or decimal degrees to Google Map projection (Spherical Mercator). Proj4Projection proj4 = new Proj4Projection(); proj4.InternalProjectionParametersString = Proj4Projection.GetEpsgParametersString(4326); proj4.ExternalProjectionParametersString = Proj4Projection.GetGoogleMapParametersString();
proj4.Open(); //Here we go from decimal degrees to Google Map projection Vertex projVertex = proj4.ConvertToExternalProjection(Longitude, Latitude);
//Here we go from Google Map projection to decimnal degrees Vertex decimalDegreesVertex = proj4.ConvertToInternalProjection(projVertex.X, projVertex.Y);
Thanks Val, it works great, I think seeing the param hint in the code completion referencing decimal degress through me of the right path a bit.
// Parameters: // feature: // This parameter is the Feature that contains a BaseShape in decimalDegreesValue // to be projected. // Thanks for your help Bennie