carlosg2 / gmaps-utility-library-flash

Automatically exported from code.google.com/p/gmaps-utility-library-flash
0 stars 0 forks source link

ArcGIS 10 #25

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I'm trying to query the feature from map services hosted on Arcgis server 10, 
but it is resulting in an error.
More importantly, when I tried doing the same with the same semantics on Map 
services hosted on Arcgis server 9.3 it worked fine.

For your information I'm using  ArcGIS Server Link for Google Maps Flash API.

When I saw the query parameter in Flash builder Watch Window they are.

[params = com.google.maps.extras.arcgislink.QueryParameters (@cd2aa39)
geometry = null
outFields = Array (@cd2b601)
[0] = "Name_E"
length = 1
returnGeometry = true
spatialRelationship = "esriSpatialRelIntersects"
text = null
where = "ID = 'AH'"
]

Error Message is:

Cannot create property fields on com.google.maps.extras.arcgislink.ResultSet.

I'm not sure if ArcGIS Server Link for Google Maps Flash API supports Arcgis 
Server 10 with its full capacity.

Platform:
ArcGIS 10 REST MapService, Google Chrome/IE8, FlashBuilder 4

Original issue reported on code.google.com by faridur.rahman on 28 Sep 2010 at 7:03

GoogleCodeExporter commented 9 years ago
Hi there,

i also wan't to upgrade my current flex project from ArcGIS Server 9.3.1 to 
ArcGIS Server 10. And i am running into a similar problem. The REST API of 
ArcGIS Server 10 has some changes to the older versions. So i guess the 
Features could not get parsed correctly.

Will ArcGIS Server will be supported soon or is it not planed?

Regards Stefan

Error Message:

ReferenceError: Error #1056: Eigenschaft fields in 
com.google.maps.extras.arcgislink.ResultSet kann nicht erstellt werden.
    at com.google.maps.extras.arcgislink::ArcGISUtil$/augmentObject()[C:\Dokumente und Einstellungen\sjung\My Documents\Flex Builder 3\GoogleMapsAPIUtilityLibrary\src\com\google\maps\extras\arcgislink\ArcGISUtil.as:356]
    at com.google.maps.extras.arcgislink::ResultSet()[C:\Dokumente und Einstellungen\sjung\My Documents\Flex Builder 3\GoogleMapsAPIUtilityLibrary\src\com\google\maps\extras\arcgislink\ResultSet.as:29]
    at Function/<anonymous>()[C:\Dokumente und Einstellungen\sjung\My Documents\Flex Builder 3\GoogleMapsAPIUtilityLibrary\src\com\google\maps\extras\arcgislink\Layer.as:146]
    at Function/http://adobe.com/AS3/2006/builtin::call()
    at Function/<anonymous>()[C:\Dokumente und Einstellungen\sjung\My Documents\Flex Builder 3\GoogleMapsAPIUtilityLibrary\src\com\google\maps\extras\arcgislink\ArcGISUtil.as:313]
    at flash.events::EventDispatcher/dispatchEventFunction()
    at flash.events::EventDispatcher/dispatchEvent()
    at flash.net::URLLoader/onComplete()

Original comment by stef.j...@gmail.com on 13 Jan 2011 at 2:15

GoogleCodeExporter commented 9 years ago
I'll look into it after sampleserver3 on arcgisonline upgraded to SP1 (10.01). 
There are some changes from 10 to 10.01 as well. If you made changes to this 
lib I'd happy to included in. 

Original comment by nian...@gmail.com on 14 Jan 2011 at 7:09

GoogleCodeExporter commented 9 years ago
A new revision is checked in with some ags10 features. Not a comprehensive 
list, but the particular problem listed here should be fixed, as in this new 
example:
http://gmaps-utility-library-flash.googlecode.com/svn/trunk/examples/ArcGISLink/
bin-release/LayerQuery3.html. 

Example index page is at 
http://gmaps-utility-library-flash.googlecode.com/svn/trunk/examples/ArcGISLink/
bin-release/index.html.

A new separate swc is created at 
http://gmaps-utility-library-flash.googlecode.com/svn/trunk/bin/ArcGISLinkLib.sw
c

or you can check out source code into your own project to compile.

Original comment by nian...@gmail.com on 20 Jan 2011 at 7:58

GoogleCodeExporter commented 9 years ago
Today i've tested the Version you provided as separate swc. I am still running 
into the same error.

When you compare the JSON from the REST API you can see there is a new object 
"fields" thats automatically send by the REST API in 10.

AGS 9.3.1:
{
    "displayFieldName" : "NAME",
    "fieldAliases" : {
        "OBJECTID" : "OBJECTID",
         ..
    },
    "geometryType" : "esriGeometryPolygon",
    "spatialReference" : {
        "wkid" : 4326
    },
    "features" : [
        {
            "attributes" : {
                "OBJECTID" : 152,
                ..
            },
            "geometry" : {
                "rings" : [
                    [
                      ..
                    ]
                ]
            }
        }
    ]
}

AGS 10:
{
    "displayFieldName" : "NAME",
    "fieldAliases" : {
        "OBJECTID" : "OBJECTID",
         ..
    },
    "geometryType" : "esriGeometryPolygon",
    "spatialReference" : {
        "wkid" : 4326
    },
    "fields": [
        {
            "name": "OBJECTID",
            "type": "esriFieldTypeOID",
            "alias": "OBJECTID"
        },
        {
            ..
        },
        ..
    ],
    "features": [
        {
            "attributes": {
                "OBJECTID": 152,
                ..
            },
            "geometry": {
                "rings": [
                    [
                       ..
                    ]
                ]
            }
        }
    ]
}

Original comment by stef.j...@gmail.com on 26 Jan 2011 at 10:43

GoogleCodeExporter commented 9 years ago
.. sry i tested it once more and now it works. Looks like it did still use the 
old library on my last tests. Dam Browser Cache...

So thanks a lot. If i find any other issues with AGS10 ill let you know.

Stefan

Original comment by stef.j...@gmail.com on 26 Jan 2011 at 12:32