Can I stop the network.request() listener ?

when I wait for the response of network.request(), can I stop the network.request() listener ?

thanks.

You can set the timeout, so if it does not respond in x seconds, it will fail and return.

cheers,

?:)

hi,JayantV ,

how can I set the timeout ?

not mention in docs.

Uh, Sorry, I was a bit mixed up between the sockets and the network.request(), Ansca officially via Joshua Quick mention

>>>>>>>>
network.request() has a 30 second request timeout on all platforms AFTER the TCP connection has been made. I believe the connection timeouts are inconsistent between platforms (we would have to do some digging on our part to figure it out), but I do know that the Corona Simulator for windows connection timeout is 1 minute.

That said, the network.request() listener will be invoked once the timeout has occurred, in which case the listener will receive an error. You can also receive error more quickly than that due to firewalls or lack of Internet connection on the device.
>>>>>>>>

However if you look at the page on Ansca documentation and read further down, you can find the relevant details here .

cheers,

?:)

and unfortunately there is no way to even cancel the network.request() so even having a timer that will cancel if you do not get any results will not work. :(

cheers,

?:)

views:1716 update:2011/10/17 8:58:49
corona forums © 2003-2011