How does Xclick work?

Hi,

I have a tricky combobox and I found Xclick usefull.

I selected the image of the combobox and indeed it selects the combobox… But only if the combobox is visible. I mean, if the combo is not visible because at the bottom of the web page, and I have to scroll to see it, it does not work. And I have an "Image “‘5xgxjm_dpi_96.png’ (conf. = 1) not found” error. Is this the normal behavior ?

I tried in browser mode / desktop mode (but the image is inside the browser so I don’t think it is relevant), with a confidence of 0.6.

I see in the forum many are using it. I suppose I do something wrong because I don’t think I have to play with the size of the browser and the scrolling bar for the image to be visible in the browser window.

Thanks for your help.

Eric.

  • Click works inside the HTML page (DOM tree, technically). So this works even if the element is not visible.

  • XClick controls the regular mouse cursor. So it works just like human, it can only click on visible elements.

“Trick”: Use “Click” or another selenium ide-style command to scroll elements into the viewport. So you can first use a Click to scroll the element up. Then it is visible. And then use XClick to send a real user mouse click to it.

image

1 Like

Hi,

Thank you for making me understand how it works !

Regards,

Eric.