Highlighted
Absent Member.
Absent Member.
268 views

the request URL and body can be parameterizied only if using callback?

 

According to '/t5/LoadRunner-and-Performance/Testing-asynchronous-business-processes-with-LoadRunner/ba-p/6029011#.WD6bl9J96mw',

The request callback is called before each request is sent. This allows you to modify the sent request (for example, it allows parameterizing the request URL and body).

Q: That mean the request URL and body can be parameterizied only if using callback?

 

For example, 

web.customRequest(

{...........

body:'ViewState=xx123yyy'}

 

Q: Can I just use parameter to replace '123' in body instead of using the concept of Callbacks?

 

Thanks a lot for the help. Hope that I have explained the question clearly.

0 Likes
1 Reply
Highlighted
Frequent Contributor.
Frequent Contributor.

Re: the request URL and body can be parameterizied only if using callback?

Sure, 

lr.saveString('456', 'param');

web.customRequest(

{...........

body:'ViewState=xx{param}yyy'});

 

Regards,

Bingle(LoadRunner R&D)

 

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.