Hi All,
We are using MS CRM 2016.
I have enabled Save and New button of quotelineitem entity by customizing the display rule and changed its default commands with the below code to copy the quoteid parent data to new record when save and new is clicked, It worked for the first time as expected
but from the new record if we again fill the data and try to click save and new it does not work. it even does not get saved or nothing happens and screen is stuck.
Is there a way to resolve this.
function SaveAndNew() {
Xrm.Page.data.save().then(OpenNewForm, function () { });
}
function OpenNewForm() {
var parameters = {};
if (Xrm.Page.getAttribute("quoteid").getValue() != null) {
parameters.quoteid = Xrm.Page.getAttribute("quoteid").getValue()[0].id;
parameters.quoteidname = Xrm.Page.getAttribute("quoteid").getValue()[0].name;
parameters.quoteidtype = Xrm.Page.getAttribute("quoteid").getValue()[0].typename;
}
Xrm.Utility.openEntityForm("quotedetail", null, parameters);
}
Regards,
Rekha J
Regards, Rekha J