web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

How to open a modal dialog in CRM Dynamics Online?

(0) ShareShare
ReportReport
Posted on by 80

Hi,

We are using CRM Dynamics online and we just started using that. We have got a requirement to show a Modal dialog on our portal home page. I tried using Xrm.internal.OpenDialog(), But it is not working. Later through some posts i realized that the this method is not supported by CRM Online. I tried showModalDialog(), but that did not work in chrome.

Can somebody please guide me on how to show popups in CRM Online? Your help is really appreciated.

Thanks,

Venu

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Tadhg Profile Picture
    75 on at

    Hello,

    A Javascript Library that you may find helpful for this is Alert.JS.

    You can find the Documentation for it here on the Git Hub for the project.

    github.com/.../alertjs

    You can show Dialogs, Web resources and IFrames using this Library.

    hope this helps,

    Tadhg.

  • Suggested answer
    Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    When you say Portal home page, what do you mean?

    Portals are an add-on feature of Dynamics CRM/365 that does not use the Xrm namespace functions for anything. If that is what you are looking for, you will have to use custom JavaScript.

    If you are looking to open a Dialog inside of of Dynamics, take a look at the following functions:

    msdn.microsoft.com/.../jj602956.aspx

    The Xrm.Utility.openWebResource might help you out here.

    If you are on D365 v9, this has been modified to Xrm.Navigation.openWebResource:

    docs.microsoft.com/.../openwebresource

    Hope this helps.

  • Vallamreddy VenuGopal Profile Picture
    80 on at

    Hi Aric,

    Thanks for your reply.

    Yes, we are trying to do that in community portal that we extended from Dynamics. If XRM name space doesn't work in portal, i need to save some data also from that popup to CRM Dynamics entity. Is it possible to access the CRM entities without Xrm name spaces in poratls? If you have done opening a popup in a portal, would you please guide me without using showmodaldialog?

    Thanks,

    Venu

  • Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    showModalDialog is no longer available in Chrome browser, so you should stay away from that.

    You can use window.open in order to implement similar functionality or build you own popup control.

    What are you trying to display in the popup?

  • Vallamreddy VenuGopal Profile Picture
    80 on at

    My requirement is like this. When the end user login to the portal for the first time, we need a display a popup with some terms and conditions and the end user has to accept those by selecting a check box on that popup which is mandatory. Also, we need to store the date and time of the acceptance in a custom entity that we create on dynamics. I am able to make the window.open() working, but through this i cannot make that mandatory.

    So, i need to open a popup that the user can only proceed further after they accept the T&cs.

    Thanks,

    Venu

  • Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    I would look this as a different route.

    Add a checkbox with a link to the T&C to the Register or Sign in page. The user will click the link, review the T&C, close the window and then click on the Checkbox.

    You can see the following post on how to create custom attributes to the sign in or register page:

    community.dynamics.com/.../customize-registration-page-in-crm-portals

    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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans