- Joined
- Feb 21, 2019
- Messages
- 168
- Reaction score
- 41
FYI, I set up a Powershell script in Task Scheduler on our server to delete old 3CX Call Reports automatically. We set ours to delete anything older than 180 days, but you can adjust as you see fit. Should be obvious where you change that.
I run this nightly to keep the files in check, as I do not want it slowly filling up my C: drive. This will only delete files and not folders.
Would be nice to have this built into 3CX. Would also be nice to put these reports elsewhere other than C:.
Get-ChildItem –Path "C:\ProgramData\3CX\Instance1\Data\Http\Reports" -file -recurse | Where-Object {($_.LastWriteTime -lt (Get-Date).AddDays(-180))} | Remove-Item -Recurse
I run this nightly to keep the files in check, as I do not want it slowly filling up my C: drive. This will only delete files and not folders.
Would be nice to have this built into 3CX. Would also be nice to put these reports elsewhere other than C:.
Get-ChildItem –Path "C:\ProgramData\3CX\Instance1\Data\Http\Reports" -file -recurse | Where-Object {($_.LastWriteTime -lt (Get-Date).AddDays(-180))} | Remove-Item -Recurse