how to pass the value of a parameter into a table/file (271 Views)
Reply
Frequent Advisor
Posts: 39
Registered: ‎01-27-2012
Message 1 of 3 (271 Views)
Accepted Solution

how to pass the value of a parameter into a table/file

guys,

 

lets say i want to capture a lot of this

Notify: Parameter Substitution: parameter "TOKEN_val" =  "AQIC5wM2LY4Sfcz-aXnMTKaEHi1wmVOH8ZZOtufHVk0dMps.*AAJTSQACMDQAAlMxAAIwMg..*"

 

into another file so that i will be able to use that to another script as an input

 

i already know how to get the token i just dont know how to SAVE it to a file/parameter so that i will just copy the file.dat

to another script

 

 

thank you in advance

Respected Contributor
Posts: 447
Registered: ‎11-25-2011
Message 2 of 3 (264 Views)

Re: how to pass the value of a parameter into a table/file

Hi pistolero,

Please find the below example.

vuser_init()
{
int i = 100;
char c = 'C';
float f = 1.234;
return 0;
}

Action()
{

int i = 100;
char c = 'C';
float f = 1.234;
long file;
char * filename = "C:\\Files\\Srihari2.txt";
// Create a new file

if ((file = fopen(filename, "w+" )) == NULL) {
lr_output_message("Unable to create %s", filename);
return -1;
}
fprintf(file, "%d %c %f", i, c, f);
fclose(file);
}

Regards,
Srihari
Valued Contributor
Posts: 117
Registered: ‎04-30-2012
Message 3 of 3 (249 Views)

Re: how to pass the value of a parameter into a table/file

For your requirement use VTS concept which will have control across the test users. In 11.50 VTS integrated as a internal component.

 

Let me know if you need any help on this.

 

Thanks, Ajay

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.