Highlighted
Absent Member.. Absent Member..
Absent Member..
879 views

Unable to generate an automatic Rich Report in Loadrunner Analysis through a Windows batch.

Hi everyone!

Here's the deal:

- We have a Report Template named "CustomReportTemplate" (created in Reports -> Reports Templates...) and an Analysis Template called MyTemplate (created in Tools -> Templates).

- CustomReportTemplate is called by MyTemplate in order to generate an automatic rich report (we just want an Excel document). When applying MyTemplate to the .lrr file that has been open (click on Apply to Session), an .lra Analysis Session is automatically generated and saved, and the Rich Report is also generated with it.

MyTemplate.PNG

- Using these templates, we want to automate the opening of a .lrr file, the application of MyTemplate to it, and thus the generation of a .lra session AND of a Rich Report - the latter being ultimately what we want to retrieve. We ticked the Automatically Save Session and Automatically Close Analysis after Saving Session boxes for a complete automation.

- We have found a Windows Command line that could potentially work:

C:\HP\Analysis\bin\AnalysisUI.exe -resultpath <complete .lrr filepath> -TemplateName MyTemplate

Using this command, the .lrr is open, the template is applied, the session (.lra) is created and saved, but the Rich Report is not generated.

- But if I do everything above manually (open the .lrr file then apply MyTemplate), it creates a Session but still no Rich Report. On the other hand, when I apply MyTemplate a second time to the session, it works! The Rich Report file is generated in the Session folder.

- So I tried a second batch opening the .lra file and applying MyTemplate:

C:\HP\Analysis\bin\AnalysisUI.exe -resultpath <complete .lra filepath> -TemplateName MyTemplate

But it doesn't work... the session is opened but no template is applied.

Any ideas or suggestions?

Of course, if some details are missing, please let me know! 🙂

I'm on Analysis 12.53, no patch installed (maybe an existing patch that I don't know of could help....)

Many thanks in advance!

0 Likes
2 Replies
Highlighted
Honored Contributor.
Honored Contributor.

Re: Unable to generate an automatic Rich Report in Loadrunner Analysis through a Windows batch.

Hi

It seems there is an issue and I was able to reproduce. We will investigate it.

In the meantime, I would suggset trying to use the Analysis API:

using the Analysis.ApiLib.dll, create a new object of the type TemplateManager

and then use the method defined in this class, ApplyTemplateFile


An example of the call and the meaning of the parameters

public void ApplyTemplateFile(     string aSessionName,    string aTemplateFileName )

'Declaration   Public Sub ApplyTemplateFile( _    ByVal aSessionName As String, _    ByVal aTemplateFileName As String _ ) 

 

Parameters 

aSessionName  

The name of the LRA file with Analysis session to which template is applied  

aTemplateFileName  

The name of the template file (*.tem) to apply to the session.

 

Highlighted
Absent Member.. Absent Member..
Absent Member..

Re: Unable to generate an automatic Rich Report in Loadrunner Analysis through a Windows batch.

Hi,

Thanks for your feedback. We will check out the API workaround.

In the meantime, please let me know if you find anything on your side, once you've investigated this issue.

Best regards.

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.