Highlighted
Regular Contributor.
Regular Contributor.
482 views

Truclient - Address Selection

Jump to solution

I've recorded a script using TruCient. there was box where  i typed address in text box, it validates and shows a matching address.  and have to selct the address from the dropdown. In the step i have chnaged ID menthod to JavaScript

evalXPath("//li[text()=\"xx King William Street, BROADMEADOWS  xxx xxxx\"]");

the highlighted is the address wanted to parameterize. Can anyone help me how to pass parameter instead of address

 

 

0 Likes
1 Solution

Accepted Solutions
Highlighted
Respected Contributor.
Respected Contributor.

Re: Truclient - Address Selection

Jump to solution

Hi Dinesh,

Try these simple steps below:

1. Create parameter file with values as needed in VU Generator itself before clicking Develop Script mode.

2. Click Develop Script and go to step where to use this one, click that step -> Go to the Value in Arguments section for that step and copy this LR.getParam('Lognumber') Note: Lognumber is my parameter name, use your own parameter name there.

Give some wait time after this step, so that it will take the proper address from parameter properly without selecting wrong one.

Kindly let me know whether it works or not. Thanks!

View solution in original post

0 Likes
3 Replies
Highlighted
Valued Contributor.
Valued Contributor.

Re: Truclient - Address Selection

Jump to solution

Hi,

Please try the following in the JavaScript editor:

var path = "//li[text()=\"" + ArgsContext.TC.getParam("ParamName") + "\"]";
evalXPath(path);

*ParamName is the name of the parameter you would like to use.

Thanks,

Einat.

 

0 Likes
Highlighted
Regular Contributor.
Regular Contributor.

Re: Truclient - Address Selection

Jump to solution

Hi,

I've tried your option. It did'nt When im  passing address through paramater it is validating address and giving some dropdown list to select. it is not selecting the same address

 

0 Likes
Highlighted
Respected Contributor.
Respected Contributor.

Re: Truclient - Address Selection

Jump to solution

Hi Dinesh,

Try these simple steps below:

1. Create parameter file with values as needed in VU Generator itself before clicking Develop Script mode.

2. Click Develop Script and go to step where to use this one, click that step -> Go to the Value in Arguments section for that step and copy this LR.getParam('Lognumber') Note: Lognumber is my parameter name, use your own parameter name there.

Give some wait time after this step, so that it will take the proper address from parameter properly without selecting wrong one.

Kindly let me know whether it works or not. Thanks!

View solution in original post

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.