Bing Api key for Hello World

287 views
Skip to first unread message

joelr...@gmail.com

unread,
Jun 10, 2016, 9:23:26 AM6/10/16
to cesium-dev
I set the key inside the BingMapsApi.js file but the globe still didn't appear. I also put the line "BingMapApi.defaultKey = 'Mykey' before the var viewer = new Cesium.Viewer('cesiumContainer') line without success.

Hannah Pinkos

unread,
Jun 13, 2016, 10:20:44 AM6/13/16
to cesium-dev, joelr...@gmail.com
Hello,

Try this:

Cesium.BingMapApi.defaultKey = '<insert bing key here>';

Best,

Hannah

Kevin Ring

unread,
Jun 13, 2016, 6:22:12 PM6/13/16
to cesiu...@googlegroups.com

That should be:

Cesium.BingMapsApi.defaultKey = '<insert bing key here>';

(Maps not Map)

--
You received this message because you are subscribed to the Google Groups "cesium-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cesium-dev+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

TS chia

unread,
Jun 20, 2017, 8:22:00 AM6/20/17
to cesium-dev



Hi Kevin,
My key as shown above, I tried, in "Hello World.html"  having the code as below but did not work. But the same key work for CesiumViewer.

function startup(Cesium) {
    'use strict';
//Sandcastle_Begin
               
Cesium.BingMapsApi.defaultKey ='--------';
               
var viewer = new Cesium.Viewer('cesiumContainer');

//Sandcastle_End
    Sandcastle.finishedLoading();
}
if (typeof Cesium !== "undefined") {
    startup(Cesium);
} else if (typeof require === "function") {
    require(["Cesium"], startup);
}


Any idea why ?
Thanks

Cheers
TS

Rachel Hwang

unread,
Jun 22, 2017, 12:09:45 PM6/22/17
to cesium-dev
Hi TS,

The code you posted works just fine in Sandcastle for me. Here's the example with our current bing key. Double check your key.


Hope that helps,
- Rachel

TS chia

unread,
Jun 27, 2017, 5:15:49 AM6/27/17
to cesium-dev
Hi  Rachel,
Thanks!
Working now.

Cheers
TS
Reply all
Reply to author
Forward
0 new messages