< Back

Test-NetMetered

Sat Jan 18, 2020 5:00 pm

NAME Test-NetMetered



SYNOPSIS

Returns if current connection is a metered connection or not.





SYNTAX

Test-NetMetered [<CommonParameters>]





DESCRIPTION

This cmdlet checks if connection is metered or not.



This is based on the example in https://msdn.microsoft.com/en-us/librar ... 35821.aspx





PARAMETERS

<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Check if connected to a metered connection



If(Test-NetMetered) { Write-Host "Metered" }











RELATED LINKS