Unable to perform Click() or Click() on a button in iFrame

Ask general questions here.
navya28
Posts: 17
Joined: Fri May 29, 2015 6:15 pm

Unable to perform Click() or Click() on a button in iFrame

Post by navya28 » Fri Oct 30, 2015 11:12 pm

Hello Support,

Since Ranorex does not support iFrame tags on RxBrowser, I decided to use default user agent for testing some test cases which had elements in iFrame tag.
However, I am not able to performClick on a button named 'Create Account' and when I perform click, My iFrame by default scrolls up and an error message is thrown saying 'Not able to click on the button since it is outside the visible desktop.
I am attaching a screenshot below. Could you please help me with it.
Attachments
SnapshotRanorex.rxsnp
(287.75 KiB) Downloaded 61 times

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 3908
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: Unable to perform Click() or Click() on a button in iFrame

Post by odklizec » Mon Nov 02, 2015 8:54 am

Hi,

Have you tried to use EnsureVisible method (Add New Action >> Invoke Action >> EnsureVisible() method)? EnsureVisible is typically done by default (depending on Global Settings). But in some cases, it's good to invoke it "manually" from recording/code.

Another thing you might try is to uncheck detection if mouse clicks/moves are within visible desktop...
VisibleDesktop.png
VisibleDesktop.png (22.32 KiB) Viewed 1486 times
And finally, instead of Mouse Click, you can try PerformClick (Add New Action >> Invoke Action >> PerformClick() method). Unlike Mouse Click, PerformClick does not move mouse to the target element, so it may click the element regardless its position.
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

navya28
Posts: 17
Joined: Fri May 29, 2015 6:15 pm

Re: Unable to perform Click() or Click() on a button in iFrame

Post by navya28 » Tue Nov 03, 2015 12:15 am

Hello Support,
I tried all the above things but none worked for me.
Is there any other way to do it
Thank you

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Unable to perform Click() or Click() on a button in iFrame

Post by Support Team » Thu Nov 05, 2015 2:30 pm

Hi navya28,

Unfortunately I was not able to reproduce this behavior on a small sample website using Mozilla Firefox in connection with the User Agent Switcher add-on.

May I ask you if we could get access to your website under test and if you could try updating Ranorex to the latest version?
Thank you.

Regards,
Markus (S)
.
Image

navya28
Posts: 17
Joined: Fri May 29, 2015 6:15 pm

Re: Unable to perform Click() or Click() on a button in iFrame

Post by navya28 » Thu Nov 05, 2015 8:54 pm

Hello Support,

The website is www.vudu.com and yes, I will try upgrading the ranorex version.

Thank you

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Unable to perform Click() or Click() on a button in iFrame

Post by Support Team » Fri Nov 06, 2015 11:03 am

Hi navya,

Thank you for providing the URL.
I've tried to click some elements within the iFrame and everything worked as expected.

Please let me know when you had the chance to update Ranorex.
Thank you.

Regards,
Markus (S)
.
Image