Print Page | Close Window

TWebGMaps - JavaScript API error message

Printed From: TMS Software
Category: VCL Components
Forum Name: VCL WebGMaps / WebOSMaps
Forum Discription:
URL: http://www.tmssoftware.com/site/forum/forum_posts.asp?TID=8097
Printed Date: 25 Sep 2018 at 7:23am


Topic: TWebGMaps - JavaScript API error message
Posted By: RANDLE MR
Subject: TWebGMaps - JavaScript API error message
Date Posted: 09 Aug 2017 at 5:46pm
Hi,

I appear to be getting the message "You are using a browser that is not supported by the Google Maps JavaScript API. Consider changing your browser.", when the map is displayed on screen.

This prevents any map pins, route calculations etc...

Platform wise;
- Windows 10
- Delphi XE 10 Seattle
- WebGMaps v2.8.0.2

Historically, it has worked (when I was on XE2, Windows 7)..?
Does anyone know how I can get this to work again please...?
KR
Ian.



Replies:
Posted By: Bruno Fierens
Date Posted: 09 Aug 2017 at 5:48pm
We have released an update today that handles this new Google limitation.


Posted By: RANDLE MR
Date Posted: 09 Aug 2017 at 6:38pm
Hi Bruno,

Thanks for the quick response.

I did note that there was an update today; but was not sure whether this was related to this issue or not - which it looks like it is.. (;->

My 2 years upgrades have expired; so to confirm, my only option to re-purchase again (less the 40% upgrade disc = 60% of the price).  I have noticed an upgrade option in the "My products" section.

Many thanks
Ian.


Posted By: Bruno Fierens
Date Posted: 09 Aug 2017 at 11:20pm
If your license was expired, you can indeed renew it at discount price and the discount offer should be displayed on your "My products" page after login on our website. If for some reason you cannot find it, please contact us by direct email so we can send the online order form link directly.


Posted By: Neil Pollard
Date Posted: 18 Sep 2017 at 1:09pm
I'm using version 2.9.1.1 with Delphi 10.2 Tokyo and WIndows 7 and I'm still getting this error message on startup.
Is there a different version I should be using?


Posted By: Bart Holvoet
Date Posted: 18 Sep 2017 at 2:16pm
Hi,

I haven't been able to reproduce this issue with TMS VCL WebGMaps v2.9.1.1.

As a workaround you can manually force your app to use a newer emulated IE version in the Windows registry by adding the executable name at the following location in the registry:

HKEY_LOCAL_MACHINE or HKEY_CURRENT_USER
\Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION

Detailed information can be found here:  https://msdn.microsoft.com/en-us/library/ee330730%28VS.85%29.aspx#browser_emulation - https://msdn.microsoft.com/en-us/library/ee330730(VS.85).aspx#browser_emulation  


Posted By: Neil Pollard
Date Posted: 18 Sep 2017 at 3:49pm
I tried various versions of emulation as shown in the link in both keys, but it hasn't eliminated the error message.

Is this error likely to cause problems with markers? I can produce a normal marker but providing a link to a PNG file doesn't use it as the marker.


Posted By: Bart Holvoet
Date Posted: 18 Sep 2017 at 4:52pm
It's unlikely that the browser version warning message is causing problems with markers.
Can you please make sure the path to the PNG file is correct and valid?
For an example using local image files you can have a look at the WebGMapsMainDemo application included with the product download.


Posted By: Neil Pollard
Date Posted: 19 Sep 2017 at 3:58am
After checking through the demos I found that the problem with the marker image was due to the file path having backslashes ( \ ) instead of forward slashes ( / ) . Changing this makes the marker visible. 


Posted By: Neil Pollard
Date Posted: 20 Sep 2017 at 3:38pm
Are you able to suggest which value should be used for the FEATURE_BROWSER_EMULATION registry setting? There are 9 values in the table provided at the link that was provided.


Posted By: Bart Holvoet
Date Posted: 20 Sep 2017 at 3:45pm
It is recommended to use the value for IE 11 (11000).

Example:




Posted By: Neil Pollard
Date Posted: 21 Sep 2017 at 8:48am
Even with that setting in the registry I still get the Javascript API error. This occurs both with my program and with the TwebGMapsDemo.exe program.

I manually added it to the HKEY_LOCAL_MACHINE section but simply running the program added the entry to the HKEY_CURRENT_USER.


Posted By: Bart Holvoet
Date Posted: 21 Sep 2017 at 9:42am
We are not aware of any issues with using the registry setting to avoid the Google Maps API warning.
I'm not sure why this solution is not working for you.
Have you tried running the application on a different machine and/or a different Windows version?


Posted By: Neil Pollard
Date Posted: 22 Sep 2017 at 3:05am
I've just tried running both my project and the TWebGMapsDemo on another Windows 7 machine. The demo project showed the error message but it disappeared when I adjusted the HKEY_CURRENT_USER registry entry.
My project ran the first time without the API error message and it automatically updated the HKEY_CURRENT_USER registry entry.
I then cleared both entries from the second machine and my project automatically created the registry entry and did not show the API error. The Demo program showed the API error, did not create the registry entry but did not show it when the entry was recreated manually.
On my normal Windows 7 machine i removed the registry entries. My project recreated the entry but showed the API error. The Demo program didn't recreate the entry and showed the API error. After manually recreating the registry entry the API error still shows.
In summation, on another machine the registry entry stopped the API error.
On my regular computer, on which I develop, the registry entry does not prevent the API error for either program.


Posted By: Bart Holvoet
Date Posted: 25 Sep 2017 at 10:56am
We haven't received any similar reports from other users after correctly setting the registry entry.
Could there be a specific difference in configuration on the machine where the issue persists that could prevent the registry entry from working correctly?


Posted By: Neil Pollard
Date Posted: 27 Sep 2017 at 2:58am
Not that I'm aware of or been able to find.
Can you suggest any areas of the registry I can look?


Posted By: Bart Holvoet
Date Posted: 27 Sep 2017 at 8:48am
I'm not sure what could be causing the issue specifically on one machine.
It may be related to the Windows version, IE version and/or other software installed on the machine.


Posted By: taufik adi sanjaya
Date Posted: 08 Oct 2017 at 2:39am
Dear admin,
im using delphi XE5 with twebgmaps version 2.9.1.1 , and then this message showing at my application

"You are using a browser that is not supported by the Google Maps JavaScript API. Consider changing your browser.Learn moreDismiss"

when i click Dismiss, then a blank white screen appears, and i cant click any location/ longitude and lattitude on app






Posted By: Bruno Fierens
Date Posted: 08 Oct 2017 at 6:03pm
Please set the IE browser emulation mode for the TWebBrowser control to Internet Explorer 11 via updating the registry.

Information for updating the registry can be found here:
https://www.cyotek.com/blog/configuring-the-emulation-mode-of-an-internet-explorer-webbrowser-control



Print Page | Close Window