Adding multi-layer ArcGIS Online feature service

2347
6
Jump to solution
02-16-2013 08:45 AM
AllisonShaw
New Contributor III
Hi,

I was wondering if anyone could help me set up config.xml correctly to reference an ArcGIS Online feature service with three sublayers, since I haven't been able to get the data to appear in the viewer. 

I tried the following to no avail to incorporate all three sublayers:

<layer label="Northern Pike" type="dynamic" visible="true" alpha="1"               
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/arcgis/rest/services/WIFO_GBT_PIKE/FeatureServer">
</layer>

I then tried to do for a single sublayer to see if type="feature" would make it work:

<layer label="Northern Pike" type="feature" visible="true" alpha="1"
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/arcgis/rest/services/WIFO_GBT_PIKE/FeatureServer/0">
</layer>

Any suggestions?

Thanks in advance for your help!
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
AllisonShaw
New Contributor III
Robert Scheitlein answered my questions when I started a new thread.  See http://forums.arcgis.com/threads/78109-missing-labels-and-pop-ups-in-feature-services?p=274679&poste....

Thanks to both of you for your help!

View solution in original post

0 Kudos
6 Replies
AllisonShaw
New Contributor III
I forgot to mention that I'm still using version 2.4 of the viewer, so maybe this old version can't handle multi-layer feature services?

Hi,

I was wondering if anyone could help me set up config.xml correctly to reference an ArcGIS Online feature service with three sublayers, since I haven't been able to get the data to appear in the viewer. 

I tried the following to no avail to incorporate all three sublayers:

<layer label="Northern Pike" type="dynamic" visible="true" alpha="1"               
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/arcgis/rest/services/WIFO_GBT_PIKE/FeatureServer">
</layer>

I then tried to do for a single sublayer to see if type="feature" would make it work:

<layer label="Northern Pike" type="feature" visible="true" alpha="1"
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/arcgis/rest/services/WIFO_GBT_PIKE/FeatureServer/0">
</layer>

Any suggestions?

Thanks in advance for your help!
0 Kudos
RhettZufelt
MVP Frequent Contributor
Hi, 

I was wondering if anyone could help me set up config.xml correctly to reference an ArcGIS Online feature service with three sublayers, since I haven't been able to get the data to appear in the viewer.  

I tried the following to no avail to incorporate all three sublayers: 

<layer label="Northern Pike" type="dynamic" visible="true" alpha="1"  
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/arcgis/rest/services/WIFO_GBT_PIKE/  MapServer"> 
</layer> 

I then tried to do for a single sublayer to see if type="feature" would make it work: 

<layer label="Northern Pike" type="feature" visible="true" alpha="1" 
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/arcgis/rest/services/WIFO_GBT_PIKE/FeatureServer/0"> 
</layer> 

Any suggestions? 

Thanks in advance for your help!


I don't use agsonline, so not sure if it is structured the same, but.. Does the above change work for you?

R_
0 Kudos
AllisonShaw
New Contributor III
I don't use agsonline, so not sure if it is structured the same, but..  Does the above change work for you?

R_


Thanks for the suggestion, but unfortunately it didn't fix it.  I am still having this problem even after splitting the feature service into two single-layer ArcGIS Online feature services--it can't even read those.  I also tried copying and pasting the xml automatically generated by the ArcGIS Viewer for Flex Application Builder 3.1 into my 2.4 application. 

Any other suggestions?  Maybe ArcGIS Online feature services are somehow different from ArcGIS Server feature services and 2.4 can't handle them or requires some different xml?
0 Kudos
RhettZufelt
MVP Frequent Contributor
Not sure if ArcGISOnline is different than a local AGS, but I don't see the respective MapService for that FeatureService (normally, there is one of each when you make a featureservice).

In any case, since it is featureservice, this is the only way I could get it to display in the viewer:

<layer label="Northern Pike YOY" type="feature" visible="true" alpha="1" 
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/ArcGIS/rest/services/WIFO_GBT_PIKE/FeatureServer/0">
</layer>

<layer label="Northern Pike Spawn Adults" type="feature" visible="true" alpha="1" 
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/ArcGIS/rest/services/WIFO_GBT_PIKE/FeatureServer/1">
</layer>
<layer label="Northern Pike Unk" type="feature" visible="true" alpha="1" 
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/ArcGIS/rest/services/WIFO_GBT_PIKE/FeatureServer/2">
</layer>


But, it does draw them correctly (at least in v3 and v31.  Don't have older version to test).

R_
0 Kudos
AllisonShaw
New Contributor III
Not sure if ArcGISOnline is different than a local AGS, but I don't see the respective MapService for that FeatureService (normally, there is one of each when you make a featureservice).

In any case, since it is featureservice, this is the only way I could get it to display in the viewer:

<layer label="Northern Pike YOY" type="feature" visible="true" alpha="1" 
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/ArcGIS/rest/services/WIFO_GBT_PIKE/FeatureServer/0">
</layer>

<layer label="Northern Pike Spawn Adults" type="feature" visible="true" alpha="1" 
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/ArcGIS/rest/services/WIFO_GBT_PIKE/FeatureServer/1">
</layer>
<layer label="Northern Pike Unk" type="feature" visible="true" alpha="1" 
url="http://services.arcgis.com/F7DSX1DSNSiWmOqh/ArcGIS/rest/services/WIFO_GBT_PIKE/FeatureServer/2">
</layer>


But, it does draw them correctly (at least in v3 and v31.  Don't have older version to test).

R_


Thanks, I tried that and it alone doesn't seem to work in 2.4, so I gave up the feature service format and got it to work as a tiled service. 

However, I need two other layers
http://services.arcgis.com/F7DSX1DSNSiWmOqh/ArcGIS/rest/services/WIFO_GBT_DUCK_RSX_TOP/FeatureServer... and http://services.arcgis.com/F7DSX1DSNSiWmOqh/ArcGIS/rest/services/WIFO_GBT_DUCK_RSX_OTHER/FeatureServ...)
to stay in feature service format so that I can use pop-ups. 

I got these two to display in the 2.4 viewer by adding "useamf=false" to the layer xml, but the labels (only found in the TOP service) don't display nor do pop-ups.  It appears that we configured the feature service wrong since the REST page says "HTML Popup Type: esriServerHTMLPopupTypeNone" so I'm going to look into that.  But I can't figure out why the non-scale dependent layers on the first service don't display...  Any ideas?
0 Kudos
AllisonShaw
New Contributor III
Robert Scheitlein answered my questions when I started a new thread.  See http://forums.arcgis.com/threads/78109-missing-labels-and-pop-ups-in-feature-services?p=274679&poste....

Thanks to both of you for your help!
0 Kudos