Click button curtained off by other window

Ask general questions here.
marcushe
Posts: 112
Joined: Tue Apr 14, 2009 6:38 am

Click button curtained off by other window

Post by marcushe » Mon Jun 22, 2009 2:58 am

1. When i run my application ,some casual popup window of other application will curtain off my button ,it will lead my program to fail. Can ranorex click covered buttons??(it is enabled ,just covered)

2. Can i set off mouse trace? during run ,ranorex will imitate entire mouse action ,moving trace and click. moving tracing is not neccessary to me ,can i set off it?

User avatar
Ciege
Posts: 1336
Joined: Thu Oct 16, 2008 6:46 pm
Location: Arizona, USA

Re: Click button curtained off by other window

Post by Ciege » Mon Jun 22, 2009 5:31 pm

By default, Ranorex (and other test automation tools) work the way a user would work. If they can't click the button, the automation script can't click the button.

Suggestions would be to make sure the form that the button lives on is activated and visible on the screen. Your code should resemble the actions a user would take. Try making a PushButtonClick method that you pass the form object and the button control name to. The method can then (each time it is called) check the validity of the button and verify that the form is visible and activated.
If this or any response has helped you, please reply to the thread stating that it worked so other people with a similar issue will know how you fixed your issue!

Ciege...

marcushe
Posts: 112
Joined: Tue Apr 14, 2009 6:38 am

Re: Click button curtained off by other window

Post by marcushe » Tue Jun 23, 2009 1:44 am

Trying

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: Click button curtained off by other window

Post by Support Team » Tue Jun 23, 2009 12:11 pm

ad 1) As Ciege already said, usually Ranorex can only do what a human user can do.
There are some cases where you can simulate a mouse click on an element without actually moving/clicking the mouse, e.g. the WebElement.PerformClick, Button.Press, or invoking the PerformClick method on a control usgin Control.InvokeMethod. However, all those methods interact with the element in way a human user can't and are therefore not recommended for testing purposes.

ad 2) If you set the mouse move time to zero, the mouse will instantly move to the specified location.

Regards,
Alex
Ranorex Support Team