PowerShell by Patrik

Get-MpPreference PowerShell Cmdlet

Gets preferences for the Windows Defender scans and updates.

Get-MpPreference
  [-CimSession <CimSession[]>]
  [-ThrottleLimit <Int32>]
  [-AsJob]
  [<CommonParameters>]

The Get-MpPreference cmdlet gets preferences for the Windows Defender scans and updates. For more information about the preferences that this cmdlet retrieves, see Windows Defender Preferences Class.

Example to view the scheduled scan day

  • The first command gets the preferences and then stores them in the $Preferences variable.
  • The second command uses standard dot syntax to display the ScanScheduleDay property of the object stored in the $Preferences variable.
$Preferences = Get-MpPreference
$Preferences.ScanScheduleDay

Details about the preferences for Windows Defender scans and updates can be found in Set-MpPreference PowerShell Cmdlet.

For additional details visit Get-MpPreference (Defender) | Microsoft Docs.

PowerShell

Comments