authenticateClientAndRetrieveSessionId error on AutocompleteMaps

Arturo González 96 Reputation points

I'm implementing Bing Maps on my webpage in order to be able to pick an address using the AutoSuggest module (from AutocompleteMaps). What I want it's something like this:

Unfortunately, when I click in the input field to fill the address, this error is appearing in the console:
Uncaught TypeError: Cannot read property 'authenticateClientAndRetrieveSessionId' of undefined

Any idea of what can be happening?
I already activated Bing Maps and I'm using the key they provided me.

I'm attaching a picture with how my code looks as I can paste it here90512-snippet.jpg

Thanks a lot!

Windows Maps
Windows Maps
A Microsoft app that provides voice navigation and turn-by-turn driving, transit, and walking directions.
193 questions
No comments
{count} votes

Accepted answer
  1. Arturo González 96 Reputation points

    Hi! I found a way to fix this.
    Instead of using that snippet, I used the one implemented in this example and now it works fine. After using that code, another error appeared saying I had to go to and create a new key. After adding that key, it worked like a charm.

    I'm attaching another snippet with how my code looks now in case it's helpful.


0 additional answers

Sort by: Most helpful