Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Dynamically changing content of web page in a IFrame not working

(0) ShareShare
ReportReport
Posted on by

I have (I think) a fairly easy question, I have created a web page in C# using some of the Dynamics components to retrieve data from my Dynamics 365 Online environment. The page contains a DropDown with lead entities, which are retrieved during the onLoad event.

When I change the dropdown value (onChange event), the data of the selected lead is begin retrieved and displayed by filling some data on the front end / html (aspx) page and the panel which contains the data is set to visible (initially this is set to false). 

This works fine when calling the page the normal way (in my web browser) but fails when I use it in a IFrame on my Dashboard. The dropdown with the lead entities is being showed and filled correctly, but it seems the onChange event is never executed.

I am probably doing something obvious wrong but I cant figure out what it is.

*This post is locked for comments

  • Community Member Profile Picture
    on at
    RE: Dynamically changing content of web page in a IFrame not working

    Brite Global

    After fixing the http problem I can now see a clear error when I do a post (execute the event), which is:

    Blocked script execution in '<URL>' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.]
    

    After reading some more about it I came across the following post about the same error: 

    https://community.dynamics.com/crm/f/117/t/152041

    Here they advised to uncheck the "restrict cross frame origin" box and so I did, this didn't helped however, which the OP of above post mentioned as well... 

  • Clem Profile Picture
    2,541 on at
    RE: Dynamically changing content of web page in a IFrame not working

    In addition, maybe i misunderstood the need here , but why do you just go for a HTML/JS file embedded in the CRM to be in the same context.

    Example : msdn.microsoft.com/.../gg328541.aspx

    Clément

  • Aric Levin - MVP Profile Picture
    30,188 Moderator on at
    RE: Dynamically changing content of web page in a IFrame not working

    Can you check your cross browser settings? Also possibly related to mixed environment http and https.

    Besides that, it would be hard to give you and exact reason.

    You can do some further investigation using Fiddler or the Browser Developer Tools (F12).

    Hope this helps.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Kudos to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Microsoft Dynamics CRM (Archived)

#1
Mohamed Amine Mahmoudi Profile Picture

Mohamed Amine Mahmoudi 83 Super User 2025 Season 1

#2
Community Member Profile Picture

Community Member 52

#3
Victor Onyebuchi Profile Picture

Victor Onyebuchi 6

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans