Bing in Basemap Gallery Widget

5439
10
06-18-2015 08:13 AM
ShawnBowers
New Contributor III

Has anyone ran into an issue where the Bing basemaps will not populate in the basemaps widget?  They are there in WAB and even when I launch it from WAB but gone once I download and put into production.  Here is what I have done so far.

Add Bing key to AGOL.

Create a Bing group.

Create a blank map with each of the three basemaps and share them with the Bing group.

Change the Basemap Gallery in my organization to the Bing group.

Created my webmap and saved using Bing Roads as it's default basemap.

When I import it into WAB everything looks fine and the gallery works.  When I deploy the app the default basemap is ESRI Streets and none of the Bing layers are there in the gallery.

Is this possibly a proxy issue?

Thanks, Shawn

Tags (1)
0 Kudos
10 Replies
HumzaAkhtar
Occasional Contributor II

I just encountered the exact same issue.   Bing maps were showing up when I was running the app through webapp builder 'startup.bat',  but they disappeared once I deployed the app on my IIS.

Did you manage to find any solution for this problem ?

0 Kudos
ShawnBowers
New Contributor III

Unfortunately, I haven't found a solution yet.  I'm also running IIS on Windows Server 2008.  I do not have a proxy setup on that machine and was wondering if that might be the issue at first.  Typically though if you can get the other basemaps loaded it isn't the proxy so I'm thinking it's an issue with WAB itself maybe not passing the Bing key now.

0 Kudos
HumzaAkhtar
Occasional Contributor II

Yes, I looked into the information passed from the portal in both cases  .  The information passed when the app was running on IIS didnot contain bingkey as well as some other parameters. 

0 Kudos
RobertScheitlin__GISP
MVP Emeritus

Humza,

   I have seen the same (no bingkey being passed once the app is deployed) and believe this is a bug that needs to be reported to esri tech support.

0 Kudos
EmersonChew2
New Contributor II

We are noticing the same thing on our end.  We did get the Bing Maps to work in a stand alone application by allowing anonymous login to our agol account.  As soon as we turned this feature off the bing maps were removed from the web application.

So...looks like it is possible however one has to make their agol count available for anonymous login which is something we want to avoid.

Esri documentation:

Configure map viewer—ArcGIS Online Help | ArcGIS

YueWu1
by Esri Regular Contributor
Esri Regular Contributor

Hi Shawn,

In order to allow the Bing Map can be displayed on stand alone host Web Application Builder(WAB), There actually two ways to make it happened. The option depends on where's the audience of your application.

  • For application only shared with your arcgis organization: Share the webmap in your organization/group, once the user sign in from the WAB application, the Bing Map will automatically display. The credential challenge is inevitable because that the way to get the Bing Map Key

  • For application shared with public: You have to have check "Allow anonymous access to your organization's website. (ess.maps.arcgis.com)" in security setting in ArcGIS Online

security.JPG

Then in the "Map" setting check "Allow this Bing key to be used in maps shared publicly by organization members". Then for your localhost application you will able to see Bing Maps.

- The reason you can view Bing Map in ArcGIS Online or Web App Builder (WAB) is because you have already log in with your organization credential. For localhost WAB application, since you shared the webmap as public, you need to allow anonymous access to view the Bing Map in your organization, otherwise you will not able to see the Bing Map based on the arcgis online documentation: Configure security settings—ArcGIS Online Help | ArcGIS

PS: There is another way to manually change the code behind the WAB to hard code the Bing Map Keys in file BaseMapGallery\Widget.js. However since Bing Map Keys are charging credits for usage, we don't recommend this workflow.

EmersonChew2
New Contributor II

Yue Wu​   Can you please provide the answer the PS portion of your last response?

We are testing portal 10.4 with server 10.4 and still find this to be a problem.  The bing key works in portal, via web app builder but once deployed to our site it drops out.

I am looking the Basemapgallery widget.js but can't seem to crack where the bing key should be hard coded.

Any help is appreciated.

0 Kudos
JacquelineKovarik1
New Contributor II

I had the same problem and found a successful solution in this thread: Adding Bing Imagery has anyone done this

0 Kudos
YueWu1
by Esri Regular Contributor
Esri Regular Contributor

Hi Emerson,

You want to make sure which way are you going to share with your user. 

  • For application only shared with your arcgis organization: Share the webmap in your organization/group, once the user sign in from the WAB application, the Bing Map will automatically display. The credential challenge is inevitable because that the way to get the Bing Map Key

 

  • For application shared with public: You have to have check "Allow anonymous access to your organization's website. (ess.maps.arcgis.com)" in security setting in ArcGIS Online

The BingMap Key is always bundle with your ArcGIS Online/Portal, you shouldn't use code to manually change this workflow. Please disregard my previous PS that is not correct. 

0 Kudos