Question

I have made a simple J2ME application using Location API to show maps on my application, when I run it on Nokia Mobile it is working fine but When I try to run it on Samsung mobile I got that error

Copyright not available

could anyone please help in that I'm using the code in this tutorial

http://www.developer.nokia.com/Community/Wiki/How_to_calculate_and_show_a_route_with_Java_ME_Location_API

it is working fine in Nokia C2 but it is not working for any Samsung mobile and produce the previous error

Was it helpful?

Solution

The Nokia Maps API for Java has been designed to work on any Java ME device, without making it specific to Nokia phones. Given the wide range of Java ME phones out there it is likely you have come across some sort of unforseen compatibility issue. (Obviously the majority of testing has occurred on Nokia phones)

The "Copyright not available" message states in full that:

An error occurred while trying to download the copyrights.Please check your internet settings.

The downloading of copyright information via http is the very first thing to be done when initialising a MapCanvas, since Nokia itself is obliged to display the copyrights on its maps where the map data has been bought in from third parties.

My guess is that either the Samsung device you are testing with is not correctly configured to connect to the Internet (maybe there is no SIM card?) or alternatively the Samsung firmware is misinterpreting the URL for downloading the copyrights as invalid.

The misinterpreted URL issue has also been observed using the Sun WTK, and the workaround (shown below) is to use the Map servers hosted in China for non-compliant SDKs as the URLs are formatted slightly differently and the devices are generally more forgiving.

// Due to an issue with the hostnames that are used it is not possible to use
// international maps at this stage on the WTK emulators. Most devices and the 
// Nokia emulators do not suffer from this limitation.
if ("SunMicrosystems_wtk".equals(
    System.getProperty("microedition.platform"))) {
            ApplicationContext.getInstance().setChina(true);
}

Obviously you''l need to use the correct values for System.getProperty("microedition.platform") to get this to work.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top