tag:blogger.com,1999:blog-3154230739686508173.post8604890279233398886..comments2023-04-02T15:36:00.230+03:00Comments on Easy way to automate testing: How to get unique file name in LoadRunner?Dmitry Motevichhttp://www.blogger.com/profile/03519257111492581809noreply@blogger.comBlogger3125tag:blogger.com,1999:blog-3154230739686508173.post-41593951895677871642009-05-25T13:03:23.149+04:002009-05-25T13:03:23.149+04:00HiDmitry,
Thank you very much for the post.
I hav...HiDmitry, <br />Thank you very much for the post.<br />I have read your article on "How to get unique file name in Loadrunner". I have a query in this, we use the following function to save a PDF file for one virtual user. <br />fp = fopen "c:\\temp\\file.pdf","wb");<br /><br />Can we use Parameterization for the variable "file.pdf" from the above function,(as "file1.pdf,file2.pdf...so on)<br /> and after if we execute the script with multiple users, it saves all the PDF files with different names.So by doing this can we skip programming part as you explained in "How to get unique file name in Loadrunner".<br />Please let me know will this solution works.<br /><br />Thanks <br />SatyaUnknownhttps://www.blogger.com/profile/00647198374143979944noreply@blogger.comtag:blogger.com,1999:blog-3154230739686508173.post-23142674753777469492008-06-02T20:05:00.000+04:002008-06-02T20:05:00.000+04:00Hi Dmitry- You may want to take a look at the web_...Hi Dmitry- <BR/><BR/>You may want to take a look at the web_save_timestamp_param function, which saves the timestamp in milliseconds to a LoadRunner parameter.<BR/><BR/>CharlieAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-3154230739686508173.post-680749789859593042008-06-02T06:38:00.000+04:002008-06-02T06:38:00.000+04:00Another (more simple?) way would be to use a combi...Another (more simple?) way would be to use a combination of native LoadRunner parameters, such as the Vuser ID, Iteration NUmber and Date/Time parameter types already available.<BR/><BR/>for example:<BR/>{vuserid}{iter_number}{dtstamp}.zip would achieve the same if u used native LoadRunner parameter types, without having to write additional C code.<BR/><BR/>Also, to get milliseconds with the Date/Time parameter just use the .000 format.<BR/><BR/>for example:<BR/>%Y%m%d%H%M%S.000 => 20080602235312.815<BR/><BR/>Regards,<BR/>TimUnknownhttps://www.blogger.com/profile/01631489382882669311noreply@blogger.com