TestProject Forum
Powered by leading experts in the test automation community

Objects not recorded if they are in iFrame

I tried to record my first project it didn’t record my action performed in iframe.

Hi Paresh. Thanks for reaching out.
The possibilty to perform actions in iframes will be released in nearest updates within next 2 weeks.

Thanks a lot for quick response, so will start exploring after newest version.

Hi there,
Did this iframe update happen?

Thanks
Hayden

Hi @H.Sinclair1,

We released a new action called “Switch to iFrame” that is part of the “Element Extensions” addon.
This action allows you to switch to a specific iframe during run time.

If your web application contains a lot of iframe elements and it’s not just about getting through a specific iframe, it will be hard for you to use the recorder. We are not allowing to test web applications that contains iframe elements.

A possible solution in your case, would be to use our Java/C# SDKs. That way, you’ll be able to create your test even with the iframe elements.

You should also know that we are changing the design of the recorder and in the future, working with iframe elements won’t be a problem any more. This redesign supposed to be completed by the end of the first quarter of 2020.

Kind regards,
Amit

Awesome Amit,

Thanks for the response, It’s just the Microsoft SSO iframe I want to navigate pass so hopefully this will work great for now.

Thank again

Hayden

Hi @H.Sinclair1,

As Marat explained to you in the chat, this addon will not resolve the login issue on MS website as the problem there is different, it is trying to get out of the contained iFrame and therefore is blocked - that’s why you see an empty screen in the recorder.

I wasn’t aware that this is your use case.

As for the MS SSO, we will investigate it and try to come up with a solution for you.

Kind regards,
Amit

Hello,

I have exactly the same problem with the elements contained in an iFrame.
The switch to iframe works wonderfully. However, is it possible to revert to default content?

Thanks,
Polu

Hi @polu,

Are you working with the recorder or with our Java/C# SDK?

A post was split to a new topic: Getting an error when running my test on a Mac agent

With the recorder. I can switch to the iFrame but not go back to the default content.

Hi @polu,

We will have to add the option to return to the default content.
I’ll let you know once it will be available.

Great! Thank you for your quick support.

You’re welcome @polu :slight_smile:

Hi @polu , we released the action to switch to default content and you’re welcomed to try it :slight_smile:
It is a part of Element Extensions addon, the action called “Switch to default content”

1 Like

Thank you @Vladyslav, it works wonderfully!

Hi Polu,
If possible can you please share the screenshots how you achieve this? Was it during recording SwitchToIframe and once enter data in that iFrame and came back to default? Thanks

Hi,

I have a problem with switching to default content from iFrame. In our web app, we have login window inside the iFrame. After typing all credentials and clicking Submit button, nothing happens (in real user flow it does). I think it is related to executing test inside the iFrame.

After login submission, I tried to add “Switch to default” action and then close the iFrame, however I am getting “Timeout occurred after 15000ms, trying to perform a click: Element was not found”. (Element X closing iFrame is outside the frame.)

Can anybody help me with this issue?

Thanks in advance

Hi @katarzyna.java,

After you complete the login steps and clicking on the Submit button, what should happen? You suppose to stay in the same iframe or move to another one?

Can you share this website with me? I want to try it myself.

Kind regards,
Amit