Select to view content in your preferred language

Can't change legend in Basic Viewer

4951
19
06-05-2015 07:19 AM
Zihan_Lin
Deactivated User

I used Basic Viewer for my app, and noticed that the I can't change Legend name.

Capture.JPG

The line in bold is the service name when I publish a service using ArcServer,

the second line "Malawi Deforestation Degradation Hotspots" is the layer name of my original map.

How can I turn off one any one of them?

0 Kudos
19 Replies
JeffWard
Honored Contributor

Have you tried right clicking on those layers and choosing Rename Layer in the Web Map?  I think that would push those layer names out to the Web App.

Jeff Ward
Summit County, Utah
Zihan_Lin
Deactivated User

Thanks Jeff! I tried it before, but didn't work. I mean, it did change the name, but I want only one name to be displayed. Capture.JPG

"Malawi 3 Forest Reserves" and "Pilot Project Forest Reserves" are the same, I just want to have one displayed.

0 Kudos
MeganMcClain
Frequent Contributor

Agree with above. You need to change it in the web map so the viewer reflects it.

0 Kudos
Zihan_Lin
Deactivated User

Each object is named twice, once in bold with underscores (the name of the actual map service) and once below that (the name of the layer).  Can we have the legend just display the layer names, so in other words remove the names that have the underscores to minimize redundancy?

Thanks for any thought.

0 Kudos
JeffWard
Honored Contributor

I don't know if you can get around having the service name show up in your legend.  Maybe you could rename the service making the new name empty?

Jeff Ward
Summit County, Utah
0 Kudos
Zihan_Lin
Deactivated User

Empty name is not allowed. It's a bug....I tried to change it the source code, still doesn't work.

0 Kudos
JeffWard
Honored Contributor

I just checked to see if you could name it to a space, but it seems any whitespace by itself is not allowed.  The only other thing I can think of is to rename it to something less noticable like the pipe '|' or an underscore or a dash.

You might want to experiment with republishing the map you used to publish the service on ArcGIS Server.  Name all of your layers and your data frame something you can live with.  I checked my basemap service I published that has many layers and my legend has the data frame name at the top, not the name of the service.  So maybe check that data frame name.

Jeff Ward
Summit County, Utah
0 Kudos
Zihan_Lin
Deactivated User

Thanks for the information! I followed your instructions but still failed. I will try again.

0 Kudos
Zihan_Lin
Deactivated User

I found one solution! Instead of adding the service, I can directly add an zipped shapefile and then there will be no service name.