MicroFocus Vugen - Data captured from response and save into file

 

Data save into File

web_custom_request("SubmittedApplication", 
        "URL=XXXXXXX", 
        "Method=POST", 
        "Resource=0", 
        "RecContentType=application/json", 
        "Referer=XXXXXXXX=yes", 
        "Snapshot=t84.inf", 
        "Mode=HTML", 
        "EncType=application/json", 
        "Body={\"XXXXXXXX”,LAST);

//Function mentioned in below this should be place in action.c

web_reg_find("Text=Submitted Applications","SaveCount=Submitted ApplicationsCount",LAST);

lr_output_message(" Application ID Submitted : %s",lr_eval_string("{workflowID1}"));

OrderID = fopen ("Appid","a+");
fprintf (OrderID, "%s \n", lr_eval_string("{workflowID1}")); 
fclose (OrderID);

//Variable declaration place in - > Globals.H

// Global Variables

long OrderID; 

char Appid[1204] = "G:\\Scripts\\Rel_name\\abc\\TC01_abc\\Appid.txt";

#endif // _GLOBALS_H


Note : file will be created in script folder with Appid name.

Comments