|
You could compare the settings in the two Location objects.
Eg. is it a street address? If so, do they match?
Are they positioned by coordinates? If so, do they match?
You could also use Gilles code (on this website) that finds the longitude and latitude of any Location object. You will have to be careful with rounding errors and decide on a tolerance value for comparing - a simple, are they equal? does not working with floating point numbers.
Eg. is lat1 == lat2?
Should really use the check lat1>(lat2-EPS) AND lat1<(lat2+EPS)
EPS should be very small - this is your tolerance value.
Richard |