NetworkItem NetworkItem NetworkItem NetworkItem Class

Represents a connected network.

Syntax

Declaration

public sealed class NetworkItempublic sealed class NetworkItemPublic NotInheritable Class NetworkItempublic sealed class NetworkItem

Properties summary

Gets the network ID.

Methods summary

Gets a NetworkTypes value indicating the network type for a NetworkItem.

Properties

  • NetworkId
    NetworkId
    NetworkId
    NetworkId

    Gets the network ID.

    public Guid NetworkId { get; }public Guid NetworkId { get; }Public ReadOnly Property NetworkId As Guidpublic Guid NetworkId { get; }

    Property Value

    • System.Guid
      System.Guid
      System.Guid
      System.Guid

      The network ID.

    Remarks

    This value can be used to retrieve the unique ID of a network if NetworkTypes is Private.

Methods

  • GetNetworkTypes()
    GetNetworkTypes()
    GetNetworkTypes()
    GetNetworkTypes()

    Gets a NetworkTypes value indicating the network type for a NetworkItem.

    public NetworkTypes GetNetworkTypes()public NetworkTypes GetNetworkTypes()Public Function GetNetworkTypes() As NetworkTypespublic NetworkTypes GetNetworkTypes()

    Returns

Device family

Windows 10 (introduced v10.0.10240.0)

API contract

Windows.Foundation.UniversalApiContract (introduced v1)

Attributes

Windows.Foundation.Metadata.ContractVersionAttribute
Windows.Foundation.Metadata.DualApiPartitionAttribute
Windows.Foundation.Metadata.MarshalingBehaviorAttribute

Details

Assembly

Windows.Networking.Connectivity.dll