ArcGIS ONLine - Control drawing order of REST Services with and without layer numbers

3705
7
06-17-2016 08:07 AM
RayCrew
Occasional Contributor II

Currently in a Web Map, it seems not possible to have full control over the drawing order if there is a mixture of REST services with and without the layer numbers specified. Those layers with a layer number specified have to draw over and those without a number specified. This may seem like a small problem, as one could republish the layers in new REST services to eliminate this. However, REST services creation takes time and hosting them uses server resources.

Does anyone have a trick for controlling this?

layer+order.png

7 Replies
KellyGerrow
Esri Frequent Contributor

HI Ray,

Can you share the web map or web services that you are using?

This documentation describes how you can organize layers in order in ArcGIS Online: Organize layers—ArcGIS Online Help | ArcGIS

I suspect you may have added a map service to the web map, when you want to reorganize the layers like a feature layer. To do this, you will need to add the feature layer (Service with the layer number appended to the end) for each layer of the map and then you will be able to reorder the layers.

-Kelly

0 Kudos
MicahBabinski
Occasional Contributor III

Hi Ray,

Are the layers all in the same service? There is an option to publish a service with the ability to Enabling dynamic layers on a map service in Manager—Documentation (10.3 and 10.3.1) | ArcGIS for Ser...​. I think you can enable this in ArcGIS Server Manager. This might allow you to reorder the layers if they are part of the same service.

RayCrew
Occasional Contributor II

Hello:

My layers are in a mix of different REST services. This new app needs some from each of the services, but not all of them. I cannot make any changes to these RESt services as they are in a locked secure environment, the typical dev, stage, publish web server setup.  The services were made for an older project and it costs me money to ask the hoster to add more. My hope is to mash up these services into the order I need without publishing them.  It appears it is simply not possible without a system change by ESRI.  I think it is warranted, as many customers are limiting in the number of REST services they can have.

0 Kudos
KellyGerrow
Esri Frequent Contributor

HI Ray,

You can change how the rest services function in the web map, based on how you add them to the map viewer. Micah Babinski​ had a great idea for enabling dynamic layers, but this would require republishing.

Try navigating to your rest URL and add all of your services to your web map as individual layers:

Add a layer like this:

http://sampleserver6.arcgisonline.com/arcgis/rest/services/Recreation/MapServer/0

Instead of :

http://sampleserver6.arcgisonline.com/arcgis/rest/services/Recreation/MapServer

If you add the layer with the number appended to the end, you will be able to reorder the layers.

-Kelly

RayCrew
Occasional Contributor II

Hello:

I would like to add each layer with the layer number defined, but, let's be honest that can be a lot of work. Some of my REST services have 10 layers that are all needed (ex: national and 1st, 2nd, 3rd and 4th level subnational boundaries that change symbology depending on scale)  and adding each one is a lot of work.

Ray

0 Kudos
MicahBabinski
Occasional Contributor III

I hear ya! It would be nice to have an AGOL utility that would allow a user to submit a service and auto-register each of the feature layers therein (maybe something like this already exists???). Ten layers isn't so bad though - my coworker and I registered 80+ individual feature layers for our AGOL Open Data site. The whole thing took probably four hours.

Micah

0 Kudos
KellyGerrow
Esri Frequent Contributor

Check out this GP tool published by Jake SkinnerAdd Individual Layers within ArcGIS Server Services as Items to ArcGIS Online/Portal

This won't add the layers to your web map, but will add the layers as items to your organization. You can then search for them by name when building the web map and have them added as feature layers.

-Kelly