/ Published in: ActionScript 3
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
//Basic Construct for an Occasional Connect var url = 'http://www.adobe.com'; var monitor = null; monitor = new runtime.air.net.URLMonitor( new air.URLRequest( url ) ); monitor.addEventListener( air.StatusEvent.STATUS, doNetworkStatus ); monitor.start(); function doNetworkStatus( e ){ if( monitor.available ){ //do something } }