Select to view content in your preferred language

Datum Transformation in Arcgis 10.1 Amersfoort_To_WGS_1984_2008_MB

2687
6
07-24-2013 11:46 PM
DavidRaijmakers
New Contributor III
I am facing the problem that the Datum Transformation isn't working from Amersfoort_To_WGS_1984_2008_MB

I found that:
Name = Amersfoort_To_WGS_1984_2008_MB
Wkid = 108457
From this pdf: http://resources.arcgis.com/en/help/main/10.1/003r/pdf/geographic_transformations.pdf

I use this code to check if there are 3 values in the url, and i look if it is the wkid of RD_NEW
if (textualMapPointAttributes.length == 3)
{
//var wkid:Number = parseFloat(textualMapPointAttributes[2]);
                 wkid = parseFloat(textualMapPointAttributes[2]);
      if(wkid==28992){
                rdCheck = true;
 }
     
}


And then in the project function this is the code:

else
                {
                    var projectParams:ProjectParameters = new ProjectParameters();
                    projectParams.geometries = [ geometry ];
     trace("input = "+ geometry.spatialReference);
                    projectParams.outSpatialReference = map.spatialReference;
     trace("output = "+ map.spatialReference);
     if(rdCheck == true){
      trace("rdcheck=true");
      var datumTransform: DatumTransform = new DatumTransform();
      datumTransform.wkid = 108457;
      datumTransform.wkt = "Amersfoort_To_WGS_1984_2008_MB";
      projectParams.datumTransform = datumTransform;
      projectParams.transformForward = true; 
      trace("rdcheck=done");

      /*projectParams.datumTransform.wkid = 108457;
      projectParams.transformForward = true;*/

     }
     trace(projectParams.datumTransform);
     
     trace(projectParams.transformForward);

     GeometryServiceSingleton.instance.project(
                        projectParams, new mx.rpc.Responder(projectionSuccessHandler,
                                                            projectionFailureHandler));

                    function projectionSuccessHandler(geometries:Array):void
                    {
                        trace("gelukt "+geometries[0]);
      responder.result(geometries[0]);
                    }

                    function projectionFailureHandler(fault:Fault):void
                    {
      trace("gefaald "+fault);

      responder.fault(fault);
                    }
                }


This is my output:

wkid is 28992
input = SpatialReference[wkid=28992]
output = SpatialReference[wkid=102100]
rdcheck=true
rdcheck=done
[object DatumTransform]
true

gefaald [RPC Fault faultString="Error executing project" faultCode="500" faultDetail=""]

Anyone know what i am doing wrong?

Or are these 3 values the only ones possible from the documentation

datumTransform property

public var datumTransform: DatumTransform

Since :  ArcGIS API 3.0 for Flex



The well-known ID or a json object specifying the datum transformation to be applied on the projected geometries. If specified, a value for transformForward parameter must also be specified. If not specified, a search is made through a set of default GeoTransformations. Currently, the following default transformations are used when applicable:


�?�esriSRGeoTransformation_NAD_1927_TO_NAD_1983_NADCON, forward and reverse, WKID=1241
�?�esriSRGeoTransformation_NAD1983_To_WGS1984_1, forward and reverse, WKID=1188
�?�esriSRGeoTransformation_NAD1927_To_WGS1984_4, forward and reverse, WKID=1173

This is an optional property and is only available with ArcGIS 10.1 and higher.


Thanks in advance
Tags (2)
0 Kudos
6 Replies
BjornSvensson
Esri Regular Contributor
Or are these 3 values the only ones possible from the documentation


No.
See http://resources.arcgis.com/en/help/arcgis-rest-api/#/Project/02r3000000pv000000/ for more info on datum transformation with ArcGIS Server. This documentation page also has a link to list of valid datum transformation ID values.  I don't see "108457" listed there, but I do see two other "Amersfoort" ones...

What version of server are you using? It needs to be 10.1 or higher.
0 Kudos
DavidRaijmakers
New Contributor III
But i already tested it in the REST interface, and it completely worked, even when i plot it on a map.

The difference without datum transformation is about 100 meters,

and with the datum transformation it is almost 0.0005m

So i don't think there isn't a sollution for this


And to your check, here it is in your site:

108457
Amersfoort_To_WGS_1984_2008_MB

And i am using 10.1 as stated in the question header
0 Kudos
DavidRaijmakers
New Contributor III
Just going to bump this question.

I really need the answer
0 Kudos
BjornSvensson
Esri Regular Contributor
David, not sure if you solved it...  If not, do you have a public test service I could play with?
0 Kudos
DavidRaijmakers
New Contributor III
Hello,

No didn't fixed it, still a dead end to me..

No sorry, we only have a secured interface..

Is there a way that you can test it?

Maybe you can test it with any other datum transformation.

And call that from the actionscript code.

Maybe then it'll just work by changing some id's?

Thanks in advance.

Greets,

David
0 Kudos
ZoranGavranic
New Contributor II
Just bumped to this question, hope that you have resolved it...

I'm doing similar thing in Silverlight, and I think that you don't need datumTransform.wkt = "Amersfoort_To_WGS_1984_2008_MB" after datumTransform.wkid = 108457; just put datumTransform.wkid = 108457.
0 Kudos