I have a TimeSpan PowerShell object and need to display it in a PRTG Custom Sensor Channel - do you have any examples that will format it whether the span contains days, hours and minutes or just minutes?
PRTG Custom Sensor - Powershell TimeSpan Object
Modified on 2025-06-10 20:21:49 +0200
Disclaimer:
The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.
The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.
Output the timespan in seconds and use the unit seconds; PRTG will then automatically convert it to minutes, hours, days, etc :)
Apr, 2022 - Permalink