|
Trying to pass a Location object from one instance of MapPoint to another isn't something I've tried - but I'm not surprised it doesn't work.
If the position of the Location is important only but not the associated information (eg. address, point of interest); then you could serialise the Location as a Longitude,Latitude coordinate.
If you search the articles section of this website, there's an article showing you how to get the Longitude,Latitude of a Location - its VB but easy to port to C++.
Then you can pass the coordinate as two doubles, and recreate it in the second MapPoint instance. This only transfers the physical position, though, and not address information or Point-of-interest information.
It is, however, quicker than doing a FindAddress or similar!
Richard |