Highlighted
Respected Contributor.. Respected Contributor..
Respected Contributor..
410 views

Capture and output system process data using UFT v12

Hi,

 

I am trying to capture some system data following an application run and hoped that someone might be able to help?

 

I want to capture the 'CPU Time' and 'Peak working set (memory)' data and output this to a Text/Excel file.

 

UFT does not seem to be able to recognise or interact with the Task Manager so my usual checkpoints cannot be used to capture this data.

 

Having interrogated both the UFT and VB help and spent a while trying to figure this out, I realise that I might be a little out of my depth in trying to write the code to do this.

 

Any assistance would be appreciated.

 

Many thanks

CH

 

OS is Win8.1

UFT v12.01 build 1112

0 Likes
2 Replies
Highlighted
Absent Member.
Absent Member.

Re: Capture and output system process data using UFT v12

Have you tried SystemMonitor.GetValue(ApplicationProcess,CounterType); its in the help file.  If you go into Test Settings, Local System Monitor, the System Counter column has a drop-down with all available System Counters.   One of the counters is "Working Set Peak".  I created a funtion that passes in the app name and counter type and then writes the results to a text file.

0 Likes
Highlighted
Respected Contributor.. Respected Contributor..
Respected Contributor..

Re: Capture and output system process data using UFT v12

Thanks RoxSmith, I had found and created the: SystemMonitor.GetValue(ApplicationProcess,CounterT​ype) part of the script, and the Settings>Local System Monitor, but its the writing this value out to a txt or Excel file that is causing me the issues. All of my (novice VBScripting skills) Dim/Sub/Function statements give me errors.  Any pointers in this area would be greatly appreciented.

 

 

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.