Parameterization in TruClient Protocol Loadrunner - JavaScript Based (Method 2 - LR.getParam)


Step 1: Create a parameter under Parameters Dialog Box (Highlighted in RED). I have created a File Parameter of name “Username”


Step 2 : Click the Develop Script button

Step 3 : Fetch the parameters from “Username” using LR.getParam function (i.e.) replace the value to be parameterized with the following code LR.getParam(“Username”) in Value filed under Arguments section. (Code Highlighted in RED)



Step 4 : By default Value  field will be in Plain Text. Now click on the drop down arrow and select JavaScript <JS>. (Highlighted in GREEN)



18 comments: