Can somebody help me or share some code about how to achieve GeoFencing on Windows Phone Mango.
I have list of GeoPositions(Latitude and Longitudes) and on every position update I want to verify that this current position is in that list which we in other words call GeoFencing, but i want to do it locally without touching any WebService etc…
So I want to know is it possible …
Also I want to achive this without blocking the main UI thread.
Please advice.
In the Microsoft sample form the Tidy app (part of the samples for Mango) – in Todo.DataAccess project,
GeoCodeDistanceCalcstatic class which calculates the distance between a pair of co-ordinates with:(where radius is the radius of the Earth in whatever unit you want the result)
For point in polygon approach, there is a whole Wikipedia article on the subject, but in the past, I’ve found the ray-casting algorithm relatively simple to implement.