Wednesday, 15 June 2011

android - How to detect exact time of Network/Internet unavailability..? -


I just want to find out the exact amp; Fast Internet connection / disconnection or connection time is no longer available. Let's assume that some time after my app is connected to some server, I have lost my connection to the server (like @ 02: 30:15 pm) Time (02:30:15 pm) or I get a warning that I have lost my contact for this particular movement.

Even if I have available Wi-Fi or data connectivity Even then I have lost my connection ..? See

link, this gives an example of a Connect / Disconnect event of the WiFi connection of the broadcast record receiver.

Apply the same Broadcast receiver to your project and listen to the Connect and Disconnect event, as well as the system time by System.currentTimeMillis () method. Then you have time to connect and disconnect.

Hope this will be helpful for you


No comments:

Post a Comment