I’ve been trying to automate a webpage that contains multiple clickable buttons. I want the robot to click on each button one by one. However, using individual Click activities for each button seems inconvenient, as there are so many buttons.
Is there a more efficient way to achieve this?
Please refer to the attached screenshot for reference.
For Each UI element activity is the solution if your buttons going to be dynamic.
If the buttons are fixed, you can take the selectors of each button into an array, iterate the array using for each and inside for each use click activity with current text or selector as selector of Click activity
I followed the steps in your screenshot, but in my case, the robot only hovers over the buttons without actually clicking them. When it does click after hovering over 5-6 buttons it stops and throws an error.
I used multiple Click activities for each button.
However, the main task I want to achieve is for the robot to click on the buttons on the left side and then read the data that appears on the right side and continue doing that for all the buttons.
Is there any better way to do it?
I tried your advice, and it did delay the process by 3 seconds as expected. However, the issue remains that the robot just hovers over the buttons without actually clicking them. Occasionally, it clicks a button after hovering over 3-4 buttons, but then it stops working entirely.
Please check the video for reference.
also try to see the selector for the curretn element …that might help to see if it is failign only at one button always which might help in knowing the issue
Yaa the webpage reloads after every click so i added a 10 seconds delay so that the webpage gets enough time to load before it goes for the next click however it didn’t workout.
Also I checked the selector it is the same for everyone but it always fails at the same button.
I didn’t get your question very well but if you mean that 「期間出力データ」is on the screen when the error occurs then yaa it is there and the robot is always failing at the same button.
I guess if you click the link, it moves another page which has same menu? if so, this way is not good. To isolate cause, can you try to use middle click instead of left, and set Simulate or ChromiumAPI as Input mode?
In this case, it may be necessary to set selector which can work any page OR go back to the first page then click next menu.