Repository navigation
Get NetworkClass
AzureDevOps edited this page Sep 25, 2026
·
1 revision
Use to determine the network class of a given IP address.
Get-NetworkClass [-IP] <String> [-ProgressAction <ActionPreference>] [<CommonParameters>]
Returns A, B, C, D or E depending on the numeric value of the first octet of a given IP address.
Get-NetworkClass -IP 172.16.1.2
B
'10.1.1.1' | Get-NetworkClass
A
The IP address to test.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: False{{Fill ProgressAction Description}}
Type: ActionPreference
Parameter Sets: (All)
Aliases: proga
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).