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)

Modal Entity Form - Redirect on Success

(0) ShareShare
ReportReport
Posted on by 130

We have configured a sub-grid with the create action loading an entity form in a modal window.  When we configure 'On success' = redirect and set the redirect page, the redirect happens within the modal window.  Is there anyway to close the modal window and redirect to another page?

Thanks in advance

*This post is locked for comments

I have the same question (0)
  • TomSmelser Profile Picture
    1,570 on at

    Hi,

    Something like this may work for you.

    window.top.location="someurl";

    More detail on top.location here:

    appendto.com/.../javascript-redirect-how-to-redirect-a-web-page-with-javascript

    Good luck!

  • RaviKashyap Profile Picture
    55,410 Moderator on at

    Hi,

    I don't think this can be done with the enity form.

    Why don't you use Web Page instead?

  • Suggested answer
    gdas Profile Picture
    50,091 Moderator on at

    Hi ,

    How you are opening modal window ? Could you please share your code.

    In general we can close the modal by using below code-

    window.close();
    closeWindow(true);

    However you mentioned mentioned you are displaying entity form I guess you can see the save and close button , or you can call this function by JavaScript as well after set the parent field value by usinb below code.

     Xrm.Page.data.entity.save('saveandclose');

    I would recommend instead of modal you can use below OOB method xrm.utility.openenityform . please refer below msdn article.

    https://msdn.microsoft.com/en-in/library/jj602956.aspx


    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