How to click on the center of an image in visual UI Testing?

Hi Team,

I am performing Visual UI Testing on the Map and i want to click on the road element to submit the report.

However i have selected pic for the road name element but while performing XClick , it is not clicking exactly in the middle for that image. Is there any way so that we can provide parameter to click at the center ?
I have highlighted image below which i have selected for visual UI test.

waiting for reply.Thanks,

Can you please add your input image to the post? I assume the large map picture above is not the input image for XClick, or?

Hello

Please find image to be click below.

areaToClick

this is snippet of road and i have use cases below -

1 - If user clicks on Road then 7 options will be displayed on the screen.

2 - If user does not click on road the 3 options will be get displayed.

The image looks ok. If you use the “Find” button to test it, is the image found at the correct place? And can you see where the mouse cursor is moved?

Also: Does Xclick normally work ok? e. g. when running DemoXClick?

Hi

Image is getting identified and getting highlighted with the Find button at correct place.

I think the issue is it always try to click at right side top of an image which eventually result into clicking above the road.

Suggestion: Try to use XClickRelative. Here the center of the pink box indicates the place to click:
rel1

Ok Thanks… I will try it on my end and will update.

Thanks again for quick reply.