<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>LoadRunner TnT &#187; web_reg_save_param</title>
	<atom:link href="http://www.loadrunnertnt.com/tag/web_reg_save_param/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.loadrunnertnt.com</link>
	<description>Performance Testing, LoadRunner Tips &#38; Tricks</description>
	<lastBuildDate>Mon, 08 Mar 2010 07:57:02 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Function web_reg_save_param and arrays</title>
		<link>http://www.loadrunnertnt.com/how-tos/130/</link>
		<comments>http://www.loadrunnertnt.com/how-tos/130/#comments</comments>
		<pubDate>Wed, 15 Oct 2008 14:10:43 +0000</pubDate>
		<dc:creator>TnT Admin</dc:creator>
				<category><![CDATA[How-Tos]]></category>
		<category><![CDATA[functions]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[web_reg_save_param]]></category>

		<guid isPermaLink="false">http://www.loadrunnertnt.com/?p=130</guid>
		<description><![CDATA[There are always situations that required us to work with dynamic data returned by the server through correlation and stored in array.  That is where web_reg_save_param comes into play of capturing a value or list of values based on a defined left boundary and right boundary.  To fully appreciate the power of LoadRunner, VUGen, is to [...]]]></description>
			<content:encoded><![CDATA[<p>There are always situations that required us to work with dynamic data returned by the server through correlation and stored in array.  That is where <strong>web_reg_save_param</strong> comes into play of capturing a value or list of values based on a defined left boundary and right boundary.  To fully appreciate the power of <strong>LoadRunner</strong>, VUGen, is to at best refrain from using those GUI features such as Correlation Studio or Runtime Viewer/Browser.<span id="more-130"></span>Let&#8217;s recap the syntax of web_reg_save_param (also available in Function Reference, &#8220;F1&#8243; key) which looks like the following:</p>
<p>web_reg_save_param(&#8220;p_EmpID&#8221;,<br />
&#8220;LB=Emp_ID=&#8221;,<br />
&#8220;RB=\&#8221;",<br />
&#8220;Ord=ALL&#8221;,<br />
&#8220;RelFrameId=1&#8243;,<br />
&#8220;Search=Body&#8221;,<br />
&#8220;IgnoreRedirections=Yes&#8221;,<br />
LAST);</p>
<p>This is familiar coding where p_EmpID will be captured with LB of EMP_ID= and RB of &#8220;.  However, another parameter to note in <strong>web_reg_save_param</strong> is the ORD, or Ordinal.  This specifies the locaiton of the value to capture if multiple occurrences of LB and RB exists.  By default, the value is ORD=ALL which meant that all occurrences will be captured.  When all occurances are captured, they are stored in an array.  The total number of values captured can be accessed by placing a _count suffix after the parameter name.  Example (note, Total_Employees have to be defined as an integer in the script):</p>
<p>Total_Employees=atoi(atoi(lr_eval_string(&#8220;{p_EmpID_count}&#8221;­));</p>
<p>While to access a specified value in the array, you will put an index after the parameter in _{index} format.  Example illustrates reading the 2nd Employee ID in the array:</p>
<p>Current_EmployeeID=atoi(lr_eval_string(&#8220;{p_Emp_ID_2}&#8221;­));</p>
<p>Of course, these are just methods to read the values extracted for your scripting work.  Hopefully, you will find it easier when you are performing scripting work.</p>
<p>NOTE (21 Oct 2008):  Corrections to the default value of the Ordinal parameter.  It should be ORD=1, meaning the first occurence, instead of ORD=ALL.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.loadrunnertnt.com/how-tos/130/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
	</channel>
</rss>
