Aug 07 2024 05:53 AM
Hello, I need assistance in adjusting the retention period for virus notifications. I am looking to have the virus notifications saved for a maximum of 1 day due to a few specific reasons.
I tried running the following PowerShell command as an administrator to achieve this:
```
Set-MpPreference -QuarantinePurgeItemsAfterDelay 1
```
However, I encountered an error message:
```
Set-MpPreference : Operation failed with the following error: 0x%1!x!
At line:1 char:2
+ Set-MpPreference -QuarantinePurgeItemsAfterDelay 1
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (MSFT_MpPreference:root\Microsoft\...FT_MpPreference) [Set-MpPreference],
CimException
+ FullyQualifiedErrorId : HRESULT 0xc0000142,Set-MpPreference
```
I am seeking guidance on how to make this adjustment successfully.
Operating System Version: 23H2 (OS Build 22631.2792)