Select to view content in your preferred language

cannot project to Albers using Project Geometries

807
3
07-15-2010 11:39 AM
ToddPierce
Deactivated User
Hello - I am using a Geometry Service in the Flex API, to convert a point from WebMercator to Albers. The direct conversion did not work, so I first converted the point to WGS 84, and that worked fine. When I go from WGS 84 to Albers Equal Area Conic, though, the code errors out.

If I try to do the projection using the ESRI sample service at
http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer/project

with input wkid= 4326, output wkid=9822, geometry =
{
"geometryType":"esriGeometryPoint",
"geometries":[{"x":-89.137,"y":28.99}]
}

I get 'error projecting geometries' as you can see here

http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer/project?inSR=4326...{%0D%0A%22geometryType%22%3A%22esriGeometryPoint%22%2C%0D%0A%22geometries%22%3A[{%22x%22%3A-89.137%2C%22y%22%3A28.99}]%0D%0A}

How exactly do I get the lat/long projected to Albers?
Tags (2)
0 Kudos
3 Replies
MehulChoksey
Esri Contributor
0 Kudos
MelitaKennedy
Esri Notable Contributor
Hello - I am using a Geometry Service in the Flex API, to convert a point from WebMercator to Albers. The direct conversion did not work, so I first converted the point to WGS 84, and that worked fine. When I go from WGS 84 to Albers Equal Area Conic, though, the code errors out.

If I try to do the projection using the ESRI sample service at
http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer/project

with input wkid= 4326, output wkid=9822, geometry =
{
"geometryType":"esriGeometryPoint",
"geometries":[{"x":-89.137,"y":28.99}]
}

I get 'error projecting geometries' as you can see here

http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer/project?inSR=4326&outSR=9822&geometries={%0D%0A%22geometryType%22%3A%22esriGeometryPoint%22%2C%0D%0A%22geometries%22%3A[{%22x%22%3A-89.137%2C%22y%22%3A28.99}]%0D%0A}

How exactly do I get the lat/long projected to Albers?


Todd,

9822 is a code for the Albers map projection. That is, the algorithm, not for a completely-defined projected coordinate system. What parameters, GCS, and units do you want to use? Perhaps we have one already defined. There are several variants for US/North America, and some for other continental regions.

Melita
0 Kudos
ToddPierce
Deactivated User
Thanks - if 9822 is not supported, then I am not sure what projection to use. Here is the content of the PRJ file for a layer that has the desired output projection:

PROJCS["Albers Conical Equal Area",GEOGCS["GCS_Sphere",DATUM["D_Sphere",SPHEROID["Sphere",6371000.0,0.0]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Albers"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",-96.0],PARAMETER["Standard_Parallel_1",29.5],PARAMETER["Standard_Parallel_2",45.5],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]]

Is there a supported ESRI WKID for this projection? Thanks.
0 Kudos