I had a requirement where we got a lookup field on the entity form and on click of that lookup user is able to either select existing record or click on new record, the new record needs to have reference of some selects which user have specified in the initial form.
CRM passes the details of parent window in the url, and used the following code to extract the id
var idMatch = (/currentid=([^&]+)/i).exec(parent.window.opener.location.search);
if (idMatch != null) {
var id = idMatch[1];
id = id.replace("%7b", "");
id = id.replace("%7d", "");
return id;
}
CRM passes the details of parent window in the url, and used the following code to extract the id
var idMatch = (/currentid=([^&]+)/i).exec(parent.window.opener.location.search);
if (idMatch != null) {
var id = idMatch[1];
id = id.replace("%7b", "");
id = id.replace("%7d", "");
return id;
}
No comments:
Post a Comment