< Back

Set-LoggingDefaultLevel

Sat Jan 18, 2020 9:51 am

NAME Set-LoggingDefaultLevel



SYNOPSIS

Sets a global logging severity level.





SYNTAX

Set-LoggingDefaultLevel [<CommonParameters>]





DESCRIPTION

This function sets a global logging severity level.

Log messages written with a lower logging level will be discarded.





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:\\>Set-LoggingDefaultLevel -Level ERROR



PS C:\\> Write-Log -Level INFO -Message "Test"

=> Discarded.











RELATED LINKS

https://logging.readthedocs.io/en/lates ... ltLevel.md

https://logging.readthedocs.io/en/lates ... ite-Log.md

https://github.com/EsOsO/Logging/blob/m ... tLevel.ps1