
Hi,
To use Google map in CRM, with below code I am getting error..
url===community.dynamics.com/.../google-maps-integration-with-dynamics-crm
<html>
<head><script>function initialize() {var map_canvas = document.getElementById('map_canvas');var map_options = {center: new google.maps.LatLng(-26.4420246,133.281323),zoom: 4,mapTypeId: google.maps.MapTypeId.ROADMAP}var map = new google.maps.Map(map_canvas, map_options)var geocoder = new google.maps.Geocoder();var address = window.parent.Xrm.Page.data.entity.attributes.get('address1_composite').getValue();geocoder.geocode( { 'address': address}, function(results, status) {if (status == google.maps.GeocoderStatus.OK) {map.setCenter(results[0].geometry.location);map.setZoom(14);var marker = new google.maps.Marker({map: map,position: results[0].geometry.location});} else {//alert("Geocode was not successful for the following reason: " + status);}});}google.maps.event.addDomListener(window, 'load', initialize);</script></head><body><div style="width: 100%; height: 100%;" id="map_canvas"></div></body></html>Hi demohun,
I tested on my D365 and got the same error message.
This is because Google Maps API no longer supports keyless access since June 22, 2016. You could refer to this Google News.
You could refer to this article to get Google Map JavaScriptAPI key.
Hope this helps.
Best Regards,
Lu Hao