Scripting - Enter value into a text box and hit tab
|
11-27-2020, 02:29 PM
(This post was last modified: 12-27-2020 12:10 PM by krishna.web.)
Post: #1
|
|||
|
|||
Scripting - Enter value into a text box and hit tab
Hi,
In my use case, i need to enter data into a text box and hit "Next" button to move to next page. I am able to enter data into text box using execAndWait & setValue. But I am not able to click on "Next" since it is in disable state. Application is not considering it as script entered the value and validated. Option #1: execAndWait document.querySelector(<JS Path>).value = "<value>"; Option #2: setValue id=<element> <value> How can I enter the data and hit a tab button or submit the data to get it validated to move further steps? Thanks, Krishna |
|||
12-27-2020, 12:11 PM
Post: #2
|
|||
|
|||
RE: Scripting - Enter value into a text box and hit tab
Worked with UI Developer and got solution for this.. Text box value get it validated automatically on click tab button or 'on control moves to next element'.
execAndWait $('#<Element_ID>').find(':input').each(function() {if($(this).prop('type') == 'text'){$(this).attr('value', "<value>").change();}}); Hopefully this solution works specific to application, same may not work for other applications. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)