Re: how to pass the value of a parameter into a table/file (100 Views)
Reply
Advisor
pistolero
Posts: 31
Registered: ‎01-27-2012
Message 1 of 3 (122 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

Please use plain text.
Respected Contributor
Srihari_Amgen
Posts: 421
Registered: ‎11-25-2011
Message 2 of 3 (115 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
Please use plain text.
Valued Contributor
Ajay_U
Posts: 108
Registered: ‎04-30-2012
Message 3 of 3 (100 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

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