Clicking is an essential task when performing automation on web applications.
Even when Leapwork is able to validate a web element, sometimes it is unable to click on specific elements due to heavy DOM or complications with iframes. When Leapwork is unable to click, the action will not be completed on the web page.
We can recommend many strategies to resolve this issue.
Methods:
Method 1. Increase the Default timeout and check "Await DOM change" in the Click Web Element block.
Method 2. Use the Find Web element with different strategies, preferably the "Root Descended Child" strategy, before the Click Web Element block.
Method 3. Use Find Web Element and then Click Web Position block.
Method 4. Use more than one Find Web Element and then click web element, if the DOM is heavy.
Suppose the strategy is like this.
Now we can split elements into two different Find Web element blocks.
Like 'a' and 'div' in first and last, last two 'div' in the other Find Web Element block.
Method 5. Try to split the class attribute of the web element.
If the class attribute is big, then we can split that into two conditions.
Method 5. Use Run Web JavaScript block to click.
Use code - return arguments[0].click()
Method 6. Use Click Image or Click Text Blocks.
And use best practices to capture the image.
For clarification, please contact our Priority Support.
Comments
0 comments
Please sign in to leave a comment.