Hello Muhammad,
As we can see when loading on the page, a few times the input element has not yet been created, which is why it has not filled in the fields. If you navigate to the Help > Studio Tab, you may see warning messages that the elements were not found.
A good practice is that every time you navigate between pages or perform an action that generates new elements on the screen, you must use the commands below:
- webWait - to wait to complete the page request
- webWaitElement - to wait for the element to load
One more observation, the time out of these commands is the maximum time that will wait for them to be loaded, if they are loaded before, the execution is continued.
Follow your code.
defVar --name firefox --type Browser
defVar --name elementExist --type Boolean
webStart --name browserFirefox --type "Firefox" firefox=value
webNavigate --url "https://ibank.bankmega.com/corp/common2/login.do?action=loginRequest"
webWait --timeout "00:00:30"
webWaitElement --selector "CssSelector" --css "#corpId" --timeout "00:00:10" elementExist=value
webSet --value test --selector "CssSelector" --css "#corpId"
webSet --value test1 --selector "CssSelector" --css "#userName"
webSet --value testpass --selector "CssSelector" --css "#passwordEncryption"
webClose --name browserFirefox --leavebrowseropen
------------------------------
Angelo Alves
IBM RPA Technical Specialist
------------------------------
Original Message:
Sent: Wed June 14, 2023 11:00 PM
From: Muhammad Ramadhan
Subject: Set Value to Field but no text was entered
Hi,
I'm new and still learning IBM RPA Studio. I have a question, when I set value to field and try to start running, no text was entered and no warning/error.
But when I start running and toggle breakpoint in set value to field section, text was entered.
How can I solved this issue?
This is the script :
defVar --name firefox --type Browser
webStart --name browserFirefox --type "Firefox" firefox=value
webNavigate --url "https://ibank.bankmega.com/corp/common2/login.do?action=loginRequest"
webSet --value test --selector "CssSelector" --css "#corpId"
webSet --value test1 --selector "CssSelector" --css "#userName"
webSet --value testpass --selector "CssSelector" --css "#passwordEncryption"
webClose --name browserFirefox --leavebrowseropen
Thank you
Wahyu
------------------------------
Muhammad Ramadhan
------------------------------