locked
How to set pop up page size and pass parameters to an entity from another page in javascript ? RRS feed

  • Question

  • How to set pop up page size and pass parameters to an entity from another page in javascript ?..I am using MS Dynamics CRM 2016....I have searched everywhere but didn't find any solution for how to set pop up page size and pass parameters to an entity from another page in javascript at one level...Please help...

    Here is my Code...But its not working...

    function ConvertToLead()
    {
    //Get Values from Phone Call
    var subject = Xrm.Page.getAttribute("subject").getValue();
    var phone = Xrm.Page.getAttribute("phonenumber").getValue();
    var to = Xrm.Page.getAttribute("to").getValue()[0].name;

    //Set Values to lead

     var parameters = {};
    parameters["subject"] = subject;
    parameters["mobilephone"] = phone;
    parameters["lastname"] = to;

    var   windowOptions = { openInNewWindow: true };
    var newWindow = Xrm.Utility.openEntityForm("lead" , null , parameters ,windowOptions);
    newWindow.moveTo(0,0);
    newWindow.resizeTo(800,600);
    }


    • Edited by Priyadarshee Thursday, December 8, 2016 12:06 PM
    Thursday, December 8, 2016 11:49 AM

All replies

  • Hi Priyadarshee,

    You can use window.open method to fulfill your requirement. Below link shows example of both the method.

    Check this 

    Hope this helps.

    Thanks

    Thursday, December 8, 2016 1:35 PM
  • Hey,

    Go through this link. It explains, how to send parameters to other entity from javascript

    https://mscrmmindfire.wordpress.com/2013/12/04/crm-2013-passing-custom-parameters-to-openentityform-function/


    Jugal Kishore Dandamudi.

    Monday, December 19, 2016 11:20 AM