Highlighted
Super Contributor.. Super Contributor..
Super Contributor..
425 views

set “Action.js” as default

Jump to solution

Hi,

I am using Loadrunner version 12.53 patch-4, Html/Http protocol.

Whenever, I open a new HTTP/HTML script it always have “Action.c”.

However, I want “Action.js” always to open.

My setting: Recording Options -> Script -> Scripting Language -> “Javascript” 

How to set “Action.js” as default? 

Thanks

0 Likes
1 Solution

Accepted Solutions
Highlighted
Outstanding Contributor.
Outstanding Contributor.

Re: set “Action.js” as default

Jump to solution

As indicated:

Scripts in the Web HTTP/HTML protocol are always created in C language.

As a workaround, I would suggest dummy-recording a blank page or not performing any operation. This will covert the script to JavaScript, but the Action.js file should be empty.

Edo

View solution in original post

0 Likes
3 Replies
Highlighted
Outstanding Contributor.
Outstanding Contributor.

Re: set “Action.js” as default

Jump to solution

Scripts in the Web HTTP/HTML protocol are always created in C language.

If your Recording Options > Scripting language is set to JavaScript, then after recording is finished, the script code will be generated in JavaScript.

To convert a recorded script from C to JavaScript, regenerate the script with the Recording Options > Scripting Language set to JavaScript.

See this article for more information: https://community.saas.hpe.com/t5/LoadRunner-and-Performance/Empowering-LoadRunner-with-JavaScript-or-C-as-a-scripting/ba-p/239918#.WfHZQteWZhw

Edo

0 Likes
Highlighted
Super Contributor.. Super Contributor..
Super Contributor..

Re: set “Action.js” as default

Jump to solution

Hi,

I know, if in Recording Options -> scripting language is set to JavaScript, then after recording, the script code will be generated in JavaScript. 

However, if I have open a new HTTP/HTML script and I do not want to recode but have written some code in JavaScript, then it gives error because default template is “Action.c”.

Thanks

0 Likes
Highlighted
Outstanding Contributor.
Outstanding Contributor.

Re: set “Action.js” as default

Jump to solution

As indicated:

Scripts in the Web HTTP/HTML protocol are always created in C language.

As a workaround, I would suggest dummy-recording a blank page or not performing any operation. This will covert the script to JavaScript, but the Action.js file should be empty.

Edo

View solution in original post

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.