Nico,

I'm new to this as well but you need to put ALL of the processing of setting 
your marker and infowindow in the call back routine after 'if (results[0])' 
so that it is not executed until your address has been geocoded 
successfully.

Using Alert delays the process sufficiently so that the code outside the 
callback doesn't get called until the callback has had time to finish. 
JavaScript doesn't have a wait function so you cant easily wait in your main 
routine for the asynchronous routine to complete.  

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-maps-js-api-v3/-/nHcpTu1y3SAJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-maps-js-api-v3?hl=en.

Reply via email to