How to corelate values in Ajax TruClient protocol

1,119 views
Skip to first unread message

Narendra Sharma

unread,
Mar 20, 2012, 2:56:16 AM3/20/12
to LoadRunner
Hi Guys,

Do you know how to co-relate values in Ajax TruClient protocol
scripts?

This is the scenario -
There is a search criterion giving me 100 search results (100 Links).
While recording, I clicked on one of those 100 links. During the test,
I want the virtual users to click on any of those links ramdomly.

Can you please help me how manage this situation?

Thanks,
Narendra

Prasenjit Dutta

unread,
Mar 21, 2012, 2:04:33 AM3/21/12
to lr-loa...@googlegroups.com
u can check the video that they have given with LR11, there they have clearly shown how to do the correlation in ajax trueclient protocol.....but if you simply want to do in https/html metod there are several ways to do it.....


--
You received this message because you are subscribed to the Google "LoadRunner" group.
To post to this group, send email to LR-Loa...@googlegroups.com
To unsubscribe from this group, send email to
LR-LoadRunne...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/LR-LoadRunner?hl=en



--
Prasenjit

Taranjot Singh

unread,
Mar 21, 2012, 3:39:23 AM3/21/12
to lr-loa...@googlegroups.com
Hi,

You need to paramaterise the search value to run for multiple users ,
during test.

And, I think there is no correlation required in AJAX TRUE Client Protocol.


On 3/21/12, Taranjot Singh <cmil...@gmail.com> wrote:

> --
> Always Keep Smiling !
>
> Taranjot Singh
>


--

--
Always Keep Smiling !

Taranjot Singh

Narendra Sharma

unread,
Mar 21, 2012, 10:43:32 AM3/21/12
to lr-loa...@googlegroups.com
Prasenjit - Are you talking about this video?
Is there any other video that you are talking about?
 
Taranjot -
How to Parameterize the search results? Have you ever tried? Do you have the code?

Taranjot Singh

unread,
Mar 22, 2012, 12:46:19 AM3/22/12
to lr-loa...@googlegroups.com
Use LR.getparam("Variable name"); Function in evulate js for paramterisation .

Narendra Sharma

unread,
Mar 22, 2012, 1:23:47 AM3/22/12
to lr-loa...@googlegroups.com
This is to get values from the parameter to a variable. Actually i was looking for a js function to capture the all values of a search result values in a parameter. Eg - Lets say a search criterion gives following result -
India
Pakistan
United States
United Kingdom
France
 
Is there a javascript function that captures all the above values in a parameter?
 
Thanks,
Narendra

Prasenjit Dutta

unread,
Mar 22, 2012, 2:28:13 AM3/22/12
to lr-loa...@googlegroups.com
@Narendra,

I was talking about the video given to the vugen starting page, please find the attached jpeg file for your information. though I have not used the Ajax true client, but the vide gives a good clear picture of that.

thanks,
Prasenjit
Untitled.jpg

Bhushan Deodhar

unread,
Mar 22, 2012, 5:14:30 AM3/22/12
to lr-loa...@googlegroups.com
I think the simplest option could be to parametrize if you could get the list of links before running your test. Else, you could write a logic to click on any random link by treating it as an array & passing an argument.

Narendra Sharma

unread,
Mar 22, 2012, 6:39:15 AM3/22/12
to lr-loa...@googlegroups.com
H Prasenjit,
 
I saw this video. It is very helpful. Thank you very much. :)
 
@All - Through Ajax tru client documents provided by HP, I found that evalXPath function can be used to save search results in a parameter array. I used it and found that LR 11 Patch 2 needs to be installed for loadrunner to recognize evalXPath. I did so and now when I am trying to replay the scripts, the Firefox stops responding and closes.
 
Can somebody pls suggest what is causing firefox to close? I am attaching the snapshot of the firefox closure message. Has somebody faced a similar issue in past? How did you resolve it?
 
 
Narendra

On Thu, Mar 22, 2012 at 11:58 AM, Prasenjit Dutta <prasen...@gmail.com> wrote:
snapshot.jpg

Innocent Neil

unread,
Jul 25, 2013, 8:18:47 PM7/25/13
to LR-Loa...@googlegroups.com, lr-loa...@googlegroups.com, narendra...@gmail.com
Can anyone please tell me if the following parameter issues was resolve by anyone? Actually I am having similar type of issues with parametrization an objects at the XPath and JavaScript Identification Methods in Ajax TrueClient Protocol? Please help me if you can guide me step by step. I am new to this protocol.

Regards,
Neil

rahul sharma

unread,
Jul 26, 2013, 12:47:22 AM7/26/13
to LR-Loa...@googlegroups.com
parameterization is very easy in Ajaxtrue client protocol . Create a parameter in Script and then call that parameter_name using javascript
like
LR.getParam("Parameter_Name") of the particular value to be parameterized .. 

Correlation is not required in AjaxTrue Client as far i have seen as it more like a gui recording protocol so scripts doesn't fail for dynamic generation 

 
--
With Regards
Rahul sharma

Jiikka

unread,
Aug 8, 2013, 8:02:27 AM8/8/13
to LR-Loa...@googlegroups.com
Hi,

Yes, you need LR 11.2 and higher version for the evalXpath functions to work which is used to select a random link.

In Object change ID Method from Automatic to Xpath.
There will be 2 or 3 Xpaths listed, Select an Xpath. Xpath should be same for different link selections except for one value which should be parameterized.
Use LR.getParam("Parameter") to create a parameter in TruClient.
Change ID method to Javascript from Xpath and substitute the parameter name in place of the variable in the Xpath

Thanks,
Jiikka. 

Ashok

unread,
Aug 14, 2013, 2:23:46 AM8/14/13
to LR-Loa...@googlegroups.com, narendra...@gmail.com
Steps to do Correlation:

There is no correlation concept in Ajax truclient protocol, but you can select randomly the links or list of values from the drop down...

1. First record the flow in develop Script mode.
2. Go to the particular step where you select the value from the list box, or link...
3. Click on that step to expand it and go to Arguments section and give Ordinal as 0
Reply all
Reply to author
Forward
0 new messages