Re: LoadRunner C#.NET Vuser (146 Views)
Occasional Advisor
Posts: 9
Registered: ‎03-04-2011
Message 1 of 3 (188 Views)

LoadRunner C#.NET Vuser

Hi All,


Please help me how to use this function in Visual Studio LoadRunner C#.NET Vuser:

LoadRunner.WebApi web = new LoadRunner.WebApi();

web.url("", "URL=");

web.submit_form("login.php", "Name=userName, Value=mercury, ENDITEM," +
                    "Name=password, Value=mercury, ENDITEM", "LAST");


I tried multiple times but system is always present incorrect page after submit form


Please help,

Thanks so much

Please use plain text.
HP Expert
Posts: 141
Registered: ‎07-21-2009
Message 2 of 3 (152 Views)

Re: LoadRunner C#.NET Vuser

Hi Phuong

Could you please add the extended log for this section?. I want to know more information about this issue.


Rodolfo Leitón

HP LR/PC Support

If you are customer you can try posting on our internal forums for more personalized support.


For LoadRunner here.
For Performance Center here.

If you find that this or any post resolves your issue, please be sure to mark it as an accepted solution

Please use plain text.
Occasional Advisor
Posts: 9
Registered: ‎03-04-2011
Message 3 of 3 (146 Views)

Re: LoadRunner C#.NET Vuser

Thanks for your reply,


LoadRunner.LrApi lr;
LoadRunner.WebApi web;

string vData = "Name=username, Value=jojo, ENDITEM, Name=password, Value=bean, ENDITEM, LAST";

string strOption = "Resource=0, RecContentType=text/html, Referer=, Snapshot=t1.inf, Mode=HTML, LAST";

web.url("index.htm", "URL=", strOption);
web.submit_form("", "Snapshot=t2.inf", vData);

And log file


Thanks so much,

Please use plain text.
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation