Hello everyone,
Can someone help me please with this code :
function setValue(executionContext)
{
var formContext = executionContext.getFormContext();
var url = formContext.getAttribute("new_urlducrm").getValue();
if (null !=url) {
var test = url.split("=").pop().replace('"','');
formContext.getAttribute("new_iddelopportunite").setValue(test);
}
}
I want to modify it to clear the new_iddelopportunite field when the content of the "new_urlducrm" is deleted.
exemple :
and now i delete the content of url du CRM but id de l'opportunité still display informations
The second point is , actually this function take this url model : alloresto.crm4.dynamics.com/main.aspx
and paste everything after "&id=" and paste it in ID de l'opportunité field : de4ddcf6-1494-41e5-8907-3279299ac8dc
But like you see it doesnt take everything after "id=" because it miss &ForceU=1131
The correct function would have paste this : de4ddcf6-1494-41e5-8907-3279299ac8dc&ForceU=1131
If Leah Ju see this, i'm sure you can help me ^^ , you're the best ;)
Cordially