In the Virtual Earth AJAX control, there are certain screens that are somewhat hard to capture and control. We pride ourselves on the level of control we give our users, so here’s a little tidbit to hopefully help you retain what hair is left atop your head. I posted an entry a while back called Geocoding with Virtual Earth that should get you this far; but, what should you do when you get a box like this and you don’t want your users to see it?
The crux of the issue is using the “what” and “where” properties together in the VEMap.Find() method. When you do this, you’re actually using a different geocoding engine than you would be if you were to leave the “what” field blank using the same VEMap.Find() method.
So, how do you work around this?
So, your code would look something like this (for solution 2):
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
Now, the thing to remember is that you’re suppressing the error so the exciting thing that happens is….nothing! But, hey, that’s what you want! You want control? You got it. Just make sure that if you suppress the error you throw one up of your own otherwise your users may sit and blankly stare at your map waiting for something to happen.