KBI 311035 New Feature: PowerShell Reports In Argent Reports


Argent Reports 3.0A-1407-B and above


Friday, 1 Aug 2014


Argent Reports now has PowerShell Reports – these reports allow native PowerShell scripts to be executed, with the output fashioned into a report

The script editor supports syntax highlighting, and Timeout in Minutes can be set (from 1 minute to 60 minutes)

PowerShell Reports also has a Test Script button – this feature tests the script and highlights any errors that were found after executing the script

Technical Background

PowerShell Reports are extremely powerful – and the PowerShell Reports will run under the security context of the Argent service account

For security, PowerShell Reports can be controlled under the ‘Create PowerShell/SQL Generic Reports‘ Right within the Security Manager

After a new install or upgrade of Argent Reports 1407-B or above, a new folder called ‘PowerShell Management‘ will be created with a sample PowerShell Report

To control the layout of the report, PowerShell Reports have three built-in functions:

Set-ColumnValue “Name” “Value”

This function stores a “Value” under the column “Name” – Argent Reports will enumerate through all unique “Name” columns and use this as the table header


This function commits values added via Set-ColumnValue to close the row of data (with respect to the final table output)

PowerShell Reports cannot be used to start Jobs, create processes, or other high-level “writing” tasks

PowerShell Reports are designed to be access or read data from systems and applications

Write-ReportError “Error Message”

This function can be used to pass errors to the Report output — errors will be listed at the top of the report, highlighted in reds — each error will be under a separate bullet points

Text that is outputted that does not match the format of the report, or errors generated via Write-ReportError, will be discarded from the report.

However, when using the ‘Test Script’ button, customers will be able to see the ‘discarded output’

This can be leveraged for advanced troubleshooting purposes when testing the script.


Upgrade to Argent Reports 3.0A-1407-B or above