Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I am new to Flex Viewer and am currently trying to view my Map Service that comes from remote Arc GIS Server over the Internet. All parameters in the config.xml file are set up as default (I made no changes to the original file) and I am trying to add a new operational layer. I have installed (locally) Apache 2.2 as my local web server and Flexviewer v 2.3.1. I am therefore using the Flexviewer through my localhost.

My map service using a single feature class, file geodatabase with the data and mxd data frame set to WGS_1984_Web_Mercator_Auxiliary_Sphere, to be consistent with the basemap layers from arcgis online.

I haven't got the ability to install flex viewer on the actual ArcGIS service (in a different office) but I have access via ArcCatalog and ArcGIS Server Manager.

I assume the problem is either a) the URL structure specifying the map service, or b) some issue with that fact that I'm using a remote ArcGIS Server map serivce?

Below is the code used in config.xml specifying my map service. Is this correct?

    <operationallayers>
        <layer label="test" type="feature" visible="true"
               url="http://myserver/arcgis/rest/services/myservice_wgs84wm/MapServer/"
    </operationallayers>   ,

where 'myservice_wgs84wm' is the name of my map service, served from my ArcGIS Server (named above as 'myserver').

Can anyone advise on the structure of my URL? Do I need to include 'REST' parameter - I don't really understand this?

I'd be grateful for any help!!

Thanks

P.S. I'm going to post cross post on the http://forums.arcgis.com/

share|improve this question
add comment

3 Answers 3

When accessing a mapservice with flex, you have to take care about the crossdomain.xml on the server on which you are accessing the mapservice.

You cand find the explications in the ArcGIS Flex documentation: http://help.arcgis.com/en/webapi/flex/help/017p/017p0000001w000000.htm

share|improve this answer
add comment

Try type="dynamic"

and do you url like this

url="http://myserver/arcgis/rest/services/myservice_wgs84wm/MapServer/0"

And see what happens.

share|improve this answer
add comment

from your configuration of the layer, it seems there lost the ">" for the tag "layer". it should be as follows:

<operationallayers>
    <layer label="test" type="feature" visible="true"
           url="http://myserver/arcgis/rest/services/myservice_wgs84wm/MapServer/" />
</operationallayers> 
share|improve this answer
    
Thanks for your suggestion. I adjusted the configuration of the layer but it did not make any changes. Any ideas would be appreciated! –  Magda Jun 8 '11 at 14:41
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.