NetworkAddressChangedEventHandler Delegate
Collapse the table of content
Expand the table of content

NetworkAddressChangedEventHandler Delegate

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

References one or more methods to be called when the address of a network interface changes.

Namespace:  System.Net.NetworkInformation
Assembly:  System.Net (in System.Net.dll)

No code example is currently available or this language may not be supported.

Parameters

sender
Type: System::Object
The source of the event.
e
Type: System::EventArgs
An EventArgs object that contains data about the event.

This delegate handles NetworkAddressChanged events raised by the NetworkChange class. For detailed information on receiving notification for network interface address change events, see the NetworkChange class overview documentation

The sender parameter passed to this event handler is always nullptr. The EventArgs object in the e parameter passed to this event handler is always empty. These parameters are not needed, since an application receiving this event can call the GetIsNetworkAvailable static method to determine network availability.

The following example uses a NetworkAddressChangedEventHandler to handle NetworkAddressChanged events and detect when network availability changes.

No code example is currently available or this language may not be supported.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2017 Microsoft