I have a situation where after the user performs a search, I automatically zoom to the location of the selected feature at a pre-defined scale. Every once in a while the extent of the polygon feature is larger than the map extent after it has been zoomed to the pre-defined scale. In the Flex API there was a nice method on the map extent called containsExtent. You passed in another extent to that method and it would return a boolean saying whether or not the current map extent fully contained the passed in map extent.
So I could run this code that would let me know if the extent of my selected polygon was not contained by the current map extent. Then I could back the map's level out a notch so the current map view would display my selected feature in its entirety.
if (!map.extent.containsExtent(selectedFeatureExtent))
{
map.level--;
}
The only semi-valuable property I see on envelope objects in the Silverlight API is intersects, but this won't perform the same type of function that containsExtent does. Can anyone provide me with a nudge in the right direction on this one?
Thanks a ton ...
Andy