CRM 2016: Social Pane Hide Add Phone Call or Add Task link
Views (1856)
To hide the "Add Phone Call" or "Add Task" link from the social pane section use the following JavaScript line in your entity's form onload script:
function Form_OnLoad()
{
setTimeout(function () {
var crmContentPnl = parent.parent.document.getElementById("crmContentPanel");
for (k = 0; k < crmContentPnl.children.length; k++)
{
if (crmContentPnl.children[k].style.visibility == "visible" && crmContentPnl.children[k].tagName.toLowerCase() == "iframe")
{
var notesControl = crmContentPnl.children[k].contentWindow.document.getElementById("notescontrolactivityContainer_notescontrol");
// phone call
notesControl.children[0].children[1].children[0].style.display = "none"; return false;');
// task
notesControl.children[0].children[1].children[1].style.display = "none"; return false;');
break;
}
}
},5000);
}
This was originally posted here.

Like
Report
*This post is locked for comments