I know there are the monitoring events to determine if you
can get to particular http url or socket. But is there an api call
I can make before I do a request to a server to determine if a
network connection is there? Basically in case the user attempts to
interact with the server between the the timeout settings of the
By "network connection", I take it you mean a physical
network connection? There's no API for this, nor would it tell you
what you want to know. A machine can have a network connection
without having network connectivity. In general, you have to simply
attempt to contact the server and fail gracefully when it's not
I am having an issue along these lines. If a machine goes
into standby while a file.upload() is running it just stops
uploading, but doesn't fire any events or anything so we have no
way to error/recover when the machine comes back.
I tried using air.URLMonitor() and air.Event.NETWORK_CHANGE
but it isn't always firing for standby. It will fire properly if I
pull the physical network cable but not on standby.
Any help? This is my last bug before I can launch my app so
any help is very appreciated!