문제

I am currently making a c# program in WPF. I am basing my codes here: http://msdn.microsoft.com/en-us/library/dd221354.aspx . Currently, I am done doing the Geocoding and Reverse Geocoding. I want to know how can I use this to know my current location automatically without inputting my latitude and longitude.

도움이 되었습니까?

해결책

Those services only response to input of either an address or coordinate. The service won't be able to tell you where you are without you providing it some information. In a WPF application you will need to make use of the Location Platform in Windows to get access to the users location from their device. The location platform will get the users location using one of several methods such as; GPS, WIFI triangulation, IP address lookup. This will provide you with the coordinate (latitude/longitude) of where you are approximately. If you want the address information then send this coordinate to the Reverse Geocoding Service. You can find information on how to use the Location platform in WPF here: http://www.codeguru.com/csharp/.net/article.php/c16973/Using-the-Windows-7-Sensor-and-Location-Platform-from-C.htm

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top