VEMap.Find is not working properly

Hello, my name is Jesus and i am working with VE5, I'm having some probles with the VEMap.Find method with where parameter, everyt ime I place an address it does not return any value, I place one addres in local.live.com and it get the correct place to place the pin, but in the api it does not work, in VE4 it works, and that is what make me concern more, I don't know if there is a special format to write the address or something, because it is not working in this version, the addres I have been testing is "417 E Carlmel St, San Maros, CA 92078", and this is the way I am making the call toi the method:

var resultsSearch = map.Find('', locStr, null, slDrawing, null, null, true, true, null, true, onFoundResults);

I don't know what el can I do.

[851 byte] By [taclejj] at [2008-1-8]
# 1

VE5 doesn't create pushpins when you search for an address. You got to add it yourself.

Code Snippet

function onFoundResults(a, b, c, d)

{

if(c != null)

{

//Add a pushpin to the first place

var shape = new VEShape(VEShapeType.Pushpin, c[0].LatLong);

shape.SetTitle(c[0].Name);

map.AddShape(shape);

}

}

Also note that map.Find doesn't return anything. var resultSearch = map.Find will always return null. You got to use the callback function to get the results.

Derrick at 2007-10-2 > top of Msdn Tech,Windows Live Developer Forums,Virtual Earth: Map Control Development...
# 2

Thanks Derrick, I have a call back function and every thing is implemented inside, and I have made some test a few mitus ago and it it working, mi problem was because I am in Mexico or because it must be some blocked ports, I am not sure what it is, but as soon as I made the test i a virtual machine in USA it works perfectly.

Thanks for your answer.

taclejj at 2007-10-2 > top of Msdn Tech,Windows Live Developer Forums,Virtual Earth: Map Control Development...

Windows Live Developer Forums

Site Classified