Investigate the functions provided for web virtual users to modify the web request header where your session ID is stored (instead of in the request.) These functions are fully documented in the online help.
James Pulley, LoadRunnewrByTheHour
http://www.loadrunnerbythehour.com/PricingMatrix
From: LR-Loa...@googlegroups.com [mailto:LR-Loa...@googlegroups.com] On Behalf Of Blessing Chisvo
Sent: Monday, March 18, 2013 10:19 AM
To: LR-Loa...@googlegroups.com
Subject: Session ID Not Recorded In VUGEN
Hi,
I have a web app that upload a file to a document management system. When I record the process in VUGEN there's no session id (on the upload part), but when I reply the script fails with "<Reply><Success>False</Success><Error>Session ID not supplied, unable to continue.</Error>".
My code looks like:
....
web_custom_request("Upload.aspx",
"URL=http://svrvmsa063.eskom.co.za/MatimbaUATFileServer/Upload.aspx",
"Method=HEAD",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Mode=HTML",
LAST);
web_submit_data("Upload.aspx_2",
"Action=http://svrvmsa063/UATFileServer/Upload.aspx",
"Method=POST",
"EncType=multipart/form-data",
"RecContentType=text/html",
"Referer=",
"Snapshot=t40.inf",
"Mode=HTML",
ITEMDATA,
"Name=file", "Value=attachment.docx", "File=yes", ENDITEM,
LAST);
......
When I view the script in Tree view, I get the following:
Request
.......
POST /MatimbaUATFileServer/Upload.aspx HTTP/1.1
SessionID: 976a338d-a427-4fd3-bdb7-27a63b1618fd
Content-Type: multipart/form-data; boundary=----------8cff062ed8b281c
Host: svrvmsa063.eskom.co.za
Transfer-Encoding: chunked
Expect: 100-continue
A1
------------8cff062ed8b281c
Content-Disposition: form-data; name="file"; filename="concept-draft-cvs20060921(1).pdf"
Content-Type: application/octet-stream
........
Response
......
HTTP/1.1 100 Continue
HTTP/1.1 200 OK
Cache-Control: private
Content-Type: text/html; charset=utf-8
Server: Microsoft-IIS/7.5
X-AspNet-Version: 4.0.30319
X-Powered-By: ASP.NET
Date: Sat, 16 Mar 2013 11:39:58 GMT
Content-Length: 159
<Reply><Success>True</Success><FilePath>C:\Windows\TEMP\SPFFileService\976a338d-a427-4fd3-bdb7-27a63b1618fd\concept-draft-cvs20060921(1).pdf</FilePath></Reply>
.............
How do I Include the session id in my web_submit_data function?
Regards,
Blessing
--
You received this message because you are subscribed to the Google Groups "LoadRunner" group.
To unsubscribe from this group and stop receiving emails from it, send an email to LR-LoadRunne...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Try recording that much part again.
And do that in the URL mode.
web_submit_data("Upload.aspx_2",
"Action=http://svrvmsa063/UATFileServer/Upload.aspx",
"Method=POST",
"EncType=multipart/form-data",
"RecContentType=text/html",
"Referer=",
"Snapshot=t40.inf",
"Mode=HTML",
ITEMDATA,
"Name=file", "Value=C:\\temp\\attachment.docx", "File=yes", ENDITEM,
LAST);