title: Google Geocoder Asynchronous Issue
body: <p>I believe that I have having a timing issue with geocoder results. See a snippet of code below. </p>
  
  <p>I am basically performing a geocode and getting the result. I then pass the result to a server side method via the jQuery AJAX call. Finally the result of the method returns a JSON object. Based on the result I may or may not perform a second geocode. This is where the problem lies.</p>
  
  <p>You can see I have a variable <code>hasResult</code> defaulted to false, and is toggled to true when a valid result has been determined. In all cases this works perfect, except when the need for a second geocode occurs. The geocode happens successfully and the code executes, but the final <code>hasResult</code> check still returns false. How can this be?</p>
  
  <pre><code>var hasResult = false;            
  geocoder.geocode({ "address": address }, function (results, status) {
      if (status == google.maps.GeocoderStatus.OK) {
          $.ajax({
              url: "URL",
              type: "POST",
              dataType: "json",
              data: results
              contentType: "application/json; charset=utf-8",
              success: function (result) {
                          if (result.Valid) {
                              hasResult = false;
                              //Some other code, works perfect                            
                          } else {
                              geocoder.geocode({ "address": result.ValidRequest }, function (resultsNew, statusNew) {
                                  if (statusNew == google.maps.GeocoderStatus.OK) {
                                      hasResult = false; 
                                      //Some other code, works perfect
                                  }
                              });
                          }
                      });
                  });
              }
          });
      }
  });
  
  if (hasResult == true) {
      alert('Success');
  } else {
      alert('Fail');
  }
  </code></pre>
  
  <p>Thanks</p>