The value of the parameter must be from -180.0 to 180.0 when getting current geocoordinates in windows phone 8 application -


here code

geocoordinatewatcher geowatcher = new geocoordinatewatcher();  geowatcher.start();  geoposition item = new geoposition();  if (double.isnan(geowatcher.position.location.altitude))   item.altitude = 0; else   item.altitude = geowatcher.position.location.altitude;   item.longitude = geowatcher.position.location.longitude;  item.latitude = geowatcher.position.location.latitude;  geowatcher.stop();  geocoordinate=new geocoordinate(item.latitude, item.longitude, item.altitude);  

at last line getting following exception.

 type argumentoutofrangeexception  exceptionmessage value of parameter must -180.0 180.0.  parameter name  value 

why getting wrong coordinates?

what problem?


Comments

Popular posts from this blog

java - nested exception is org.hibernate.exception.SQLGrammarException: could not extract ResultSet Hibernate+SpringMVC -

sql - Postgresql tables exists, but getting "relation does not exist" when querying -

asp.net mvc - breakpoint on javascript in CSHTML? -