2 Replies Latest reply on Jan 25, 2013 1:21 AM by HelpPinky

    how do i sense if pdf is in offline or online mode?

    HelpPinky

      is the any method or any way from which i can know if the network is down in adobe (i.e.internet is not available).

      if no built-in method, how can i achieve this. I need to sense if the pdf is working offline or online?

        • 1. Re: how do i sense if pdf is in offline or online mode?
          Dave Merchant MVP & Adobe Community Professional

          At what point are you needing to check? For example if you're trying to launch a URL and it fails, there will be an exception thrown.

           

          The JavaScript API doesn't have a fundamental "is the Internet connected?" method as connectivity is server-specific. There are only a limited number of things you can do in JS that involve network traffic returning to the application (e.g. form submission with FDF and SOAP), and you cannot ping a remote server with Acrobat JavaScript. It's possible to implement a ping system using a Rich Media annotation and some Flash code, but you have no way of knowing if the user is really offline, or whether they simply clicked "Deny" when the Flash Player security prompt appeared.

          • 2. Re: how do i sense if pdf is in offline or online mode?
            HelpPinky Level 1

            basically i use the dataconnection.execute() method to connect to my server. I have put it in a exception handling. So i catch the exception succesively.

             

            Now it fails due to mainly 2 reasons. If server is down & due to yellow message box (Adobe Enhanced Security feature.)

             

            i cant distinguish between the 2 exceptions , as only GeneralException is thrown for both.

             

            How do i distinguish between them as i want to ignore the yellow message box exception.

             

            Please help, any sugestion would be appreciate