Sorry! - I confused myself and probably you by talking about
setTimeout in this context - I was thinking about the use of
setTimeout to slow the rate of directionsRequests or geocoding so as
not to fall foul of the request limits.
Rossko is right that you have to wait for the result before you use
Thank you for all your replies. I really appreciate them :). For those
who requested that I make the file publicly available I have done so
here http://aspspider.net/DarkStorm490/ . Click on the 'Change2'
button to execute the calcDistance function.
On Oct 20, 1:05 am, Rossko wrote:
> You should
Thank you all for your replies, I really appreciate them :). In
response to those who requested me to get the page up publicly; I have
done so here http://aspspider.net/DarkStorm490/ . Click 'Change2'
button to execute the calcDistance function.
On Oct 20, 1:05 am, Rossko wrote:
> You should aban
You should abandon the use of document.write
When that's used _after_ the webpage has been rendered, it generally
destroys the webpage.
Getting directions takes time from the remote service, so not only do
you need to use the results only after they have become available
(i.e. in the callback) - y
Hi Daniel
quick reply:
setTimeout - you are on the right track. Javascript has no actual
'wait for x', but you can use setTimeout to delay the running of a
function.
Essentially you use setTimeout to run the first request. Within that
request, after you get the okay, you again use setTimeout to del
Daniel
It looks like your stack of document.writes at the bottom are called
as soon as your for loop finishes, which could be before some (or all)
of the asynchonous directionsService requests complete. You need to
assure that each of your directionsService requests have completed
(not just retur
There are multiple ways to temporarily host a file publicly for
debugging purposes - we'll help you once you get a publicly available
link.
Here's a hint though - you can only work with the results inside the
callback function.
Chad Killingsworth
On Oct 18, 7:34 pm, Daniel wrote:
> Thank you fo
Thank you for both of your replies. I have been searching for quite
some time after Rossko's suggestion directing me to search the group
for 'multiple routes'. I came to the same conclusion as what you have
stated Stu, however I do not know how to 'wait for a result' before
proceeding. Is there som
Hi
you are probably going to have to supply a url with a (non)-working
example if you want too much help, but I'd guess from your description
that you are not taking account of the fact that route requests are
asynchronous, so you might be looking for the result *before* the
result has been returne
> I am currently having a problem when calculating multiple routes. What
> I am try to do is:
Search this group for 'multiple routes'
http://groups.google.com/group/google-maps-js-api-v3/search?group=google-maps-js-api-v3&q=multiple+routes
Note the limits
--
You received this message because you
10 matches
Mail list logo