printReport CLI command does not support report template functions and variables

Hello,

I am unable to use these RealityCapture Help variables in the -printReport CLI command.

The global variables (See: RealityCapture Help) like dateTime and appVersion work correctly in the printReport command.
Eg (works):
%RC% -stdConsole -headless -load %PROJECT% -printReport "Date: $(dateTime) $(appVersion) $(units)" -quit

I need a way to get report data via the console, rather than having to generate new report templates each time I want a unique report.

What I need:
%RC% -stdConsole -headless -load %PROJECT% -printReport "Components: $IterateComponents()" -quit

Perhaps there is already a way to do this but I cannot find any documentation.

Or even better than that a -jsonReport command that returns data in json format using the same functions and variables available in the reports. :slight_smile:

Kind regards!

Hi @Thorlon1
The option how to use those is like this:
To use the component’s variables for -printReport command it needs to be used like:

-printReport “Components: $IterateComponents( $ComponentInfo( componentGUID, GUID: $(componentGUID) Name: $(componentName) Cameras count: $(componentCamerasCount) Points count: $(componentPointsCount)))”

Hello Ondrej,

Thank you for the help. I must have been unsure how to correctly format the information. I appreciate the support.

I have been able to run the command you provided successfully.