How can I change the source of layer in AGOL webmap to the view layer?

659
3
05-13-2022 07:38 AM
Labels (1)
Jan2
by
New Contributor

Hi,  Today I created a map in AGOL and set up the symbology, pop ups for the various layers.  However I later created a view version of the layer and would like to change the source of the layer to the view in the webmap without having to configuring popups and symbology etc. again.  Is there any easy way to do that?  

0 Kudos
3 Replies
jcarlson
MVP Esteemed Contributor

There is! The AGO Assistant is what you want. In the top menu bar, click on "I want to...", then select "Update the URLs of Services in a Web Map".

jcarlson_0-1652452849542.png

Then just find your web map and update the URL to point to the view layer.

jcarlson_1-1652452946250.png

 

 

- Josh Carlson
Kendall County GIS
Jan2
by
New Contributor

Hi,  This doesn't seem to work for me.  Can I check, when you press 'replace' does something pop up that you have to click to confirm?  I suspect that I am not able to process this because popups are being prevented by my organisation.  Thanks

0 Kudos
jcarlson
MVP Esteemed Contributor

I don't think so. But no matter, you can do this same thing more directly using the other option to view/edit the JSON.

jcarlson_0-1652701630725.png

One of the items in the operationalLayers list will be your layer, and the url is the property you need to update. You can even use ctrl+f and get a find-and-replace dialog in the JSON editor as well!

jcarlson_1-1652701766148.png

Some people prefer the other method because you can't accidentally break your map by misplacing a comma or something. But as long as you're careful, you should be all right. If I have larger edits to make, I will often copy the JSON to a text editor and make my changes there, so that I have the undo option if something doesn't work.

- Josh Carlson
Kendall County GIS
0 Kudos