how to get connection status to connect to internet? RRS feed

  • Question

  • Hi ,

    I am using html5 / javascript to develop a metro style app. I would like to check that this application is connected with internet (online).

    I found this: Windows.Networking.Connectivity. But I did not find the related information.

    Any sample code for it? Thanks.

    Monday, October 1, 2012 6:22 AM


  • you can use:

    if (!Windows.Networking.Connectivity.NetworkInformation.getInternetConnectionProfile()) {
                        // no internet

    • Marked as answer by FugersonHall Tuesday, October 2, 2012 4:20 AM
    Monday, October 1, 2012 12:08 PM