AnsweredAssumed Answered

Buffer on dynamic MAP throughs error in Server side SDK 10.22

Question asked by suppriya on Mar 3, 2015

hi

 

I am using IOS 7, AGSIOSSDK - 10.2.2 , server side SDK is 10.22

 

i am getting below error for Server SDK 10.2.2 but perfect with 10.04:

 

Printing description of $1:

Error Domain=NSCocoaErrorDomain Code=500 "Unknown error occurred" UserInfo=0x1a94ff40 {NSURL=http://tasks.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer/project?f=json&outSR=102696&inSR=4326&geometries=%7B%22geometryType%22%3A%22esriGeometryPoint%22%2C%22geometries%22%3A%5B%7B%22x%22%3A73.828399658203125%2C%22y%22%3A15.389193534851074%2C%22spatialReference%22%3A%7B%22wkid%22%3A4326%7D%7D%5D%7D, NSLocalizedDescription=Unknown error occurred, NSLocalizedFailureReason=Unknown error occurred}

 

my code :

    NSMutableArray *arrProjectGeomtery =[[NSMutableArray alloc] init];

    AGSSpatialReference *s_Bufferref = [[[AGSSpatialReference alloc] initWithWKID:4326 WKT:m_mapView.spatialReference.wkt] autorelease];

    AGSPoint *m_ProjectedPoint =[[AGSPoint alloc] initWithX:[m_strLongitude floatValue] y:[m_strLatitude floatValue]spatialReference:s_Bufferref];

    [arrProjectGeomtery addObject:m_ProjectedPoint];

    self.m_geometryServiceTask = [[[AGSGeometryServiceTask alloc] initWithURL:[NSURL URLWithString:@"http://tasks.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer"]] autorelease];

    self.m_geometryServiceTask.delegate = self;

    AGSSpatialReference *m_sref = [[AGSSpatialReference alloc] init];

   

    if(self.m_mapView.spatialReference.wkid==0)

    {

       m_sref = [[[AGSSpatialReference alloc] initWithWKID:4326 WKT:m_mapView.spatialReference.wkt] autorelease];

    }

    else

    {

     m_sref = [[[AGSSpatialReference alloc] initWithWKID:self.m_mapView.spatialReference.wkid WKT:nil] autorelease]; 

    }

    [self.m_geometryServiceTask projectGeometries:arrProjectGeomtery toSpatialReference:m_sref];

 

plz. do help me out ....... Same work with Server side SDK 10.04.

 

do help me out...

Outcomes