Ask a Question

Clicking certain area of an object on different screen sizes

nsievert
Contributor

Re: Clicking certain area of an object on different screen sizes

Hey Alex, 

 

I tried this and am getting: "There was an attempt to perform an action a point, which beyond the screen"

I tried different pixel counts where you have the 10 and 5 as well. 

AlexKaras
Community Hero

Re: Clicking certain area of an object on different screen sizes

Hi,

 

"There was an attempt to perform an action a point, which beyond the screen"

This means that coordinates were calculated incorrectly 🙂

Stop script on the breakpoint at the line with the call to .Click() method and check that calculated coordinates are somewhere within the area with the ellipsis button.

The general idea is to get coordinates of the top-right corner of the control that contains ellipsis button and then shift down and to the left so that click was performed over the button.

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================
nsievert
Contributor

Re: Clicking certain area of an object on different screen sizes

When you say check the calculated coordinates, do you mean within the Locals debugger? And find the object in question: panelDevicedatacontainer?

AlexKaras
Community Hero

Re: Clicking certain area of an object on different screen sizes

do you mean [...]

Yes for both your questions.

 

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================
nsievert
Contributor

Re: Clicking certain area of an object on different screen sizes

Hey Alex, 

Please see attached picture.

Am I looking for height and width of the object in question? I see clientHeight = 52 and clientWidth = 155 for page.panelDevicecardcontainer.panelDevicedatacontainer.  

ClientTop is 0 though so doing Top - 5 would be negative. Is that what's causing the above error?

 

Re: Clicking certain area of an object on different screen sizes

@AlexKaras  or @Marsha_R 

 

Alternatively, is there a way to select the button via the HTML class name?

See attached picture.

 

 

cancel
Showing results for 
Search instead for 
Did you mean: