Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8925531
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T07:43:24+00:00 2026-06-15T07:43:24+00:00

I would like to check the network status on the iPad with Adobe Air,

  • 0

I would like to check the network status on the iPad with Adobe Air, at this moment i am checking by sending a URLREQUEST to Google.com. Is there any other better way to monitor the network status, and know if there is a connection or connection have been dropped. Thanks for any suggestion.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T07:43:25+00:00Added an answer on June 15, 2026 at 7:43 am

    Tricky part here we are not ping some interval times. so we use

    NativeApplication.nativeApplication.addEventListener(Event.NETWORK_CHANGE, onNetwork_ChangeHandler);
    

    It will trigger when ever change net status change so performance wise also good.

    Because Ping is very costly operation.So call start() URLMontior after network changed triggered then we call stop().

          package com.abc.net
        {
        import air.net.URLMonitor;
        import flash.desktop.NativeApplication;
        import flash.events.Event;
        import flash.events.EventDispatcher;
        import flash.events.IEventDispatcher;
        import flash.events.StatusEvent;
        import flash.net.URLRequest;
    
        [Event(name="networkStatusChanged", type="flash.events.Event")]
        public class NetStatusMonitor extends EventDispatcher
        {
            private var urlMonitor:URLMonitor;
            private var url:String;
    
            public function KBNetStatusMonitor(url:String = 'http://www.adobe.com')
            {
                super();
                this.url = url;
                NativeApplication.nativeApplication.addEventListener(Event.NETWORK_CHANGE, onNetwork_ChangeHandler);
            }
    
            protected function onNetwork_ChangeHandler(event:Event):void
            {
                start();
            }       
    
            public function start():void
            {
                urlMonitor = new URLMonitor(new URLRequest(url));
                urlMonitor.addEventListener(StatusEvent.STATUS, onNetStatus_ChangeHandler);
    
                if(!urlMonitor.running)
                    urlMonitor.start();
            }
    
            public function stop():void
            {
                if(urlMonitor.running)
                    urlMonitor.stop();
            }
    
            private function onNetStatus_ChangeHandler(event:StatusEvent):void
            {
                trace("event code " + event.code);
                trace("event level " + event.level);
                dispatchEvent(new NetStatusEvent(NetStatusEvent.NETWORK_STATUS_CHANGED,urlMonitor.available));
                stop();
            }
        }
    }
    

    Event Class

    package com.abc.net
    {
        import flash.events.Event;
    
        public class NetStatusEvent extends Event
        {
            public static const  NETWORK_STATUS_CHANGED:String = "networkStatusChanged";
    
            public var status:Boolean;
    
            public function NetStatusEvent(type:String, status:Boolean, bubbles:Boolean=false, cancelable:Boolean=false)
            {
                super(type, bubbles, cancelable);
                this.status = status;
            }
    
            override public function clone():Event
            {
                return new NetStatusEvent(type, status, bubbles,cancelable);
            }
    
        }
    }
    

    Usage :

    var netStatusMonitor:NetStatusMonitor = new NetStatusMonitor();
        netStatusMonitor.addEventListener(NetStatusEvent.NETWORK_STATUS_CHANGED,function(event:NetStatusEvent):void {
               statusCallBack.call(null,event.status);
    });
    
    netStatusMonitor.start();
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to check a network devices status e.g. promiscous mode. Basically like
I would like to check what colors is present in a image. This will
Possible Duplicate: How to check network type in iPhone app I would like to
I would like to implement check network connection before the tabs are loaded. Can
As asked, I would like my script to check network bandwidth giving me any
I would like to check to see if a DOM Node is inside an
I would like to check if a few URL's exst on my old website
I would like to check whether the request is XML od HTML. When HTML
I would like to check if an object is defined or exists using C#.
I would like to check the memory consumption of each running processes individually, cat

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.