Hello Everyone
I have following 2 functions in a web resource.
function ConvertRecordingFieldToLink(fieldid)
{
var c = document.getElementById(fieldid);
if (c == null)
return;
if (c.value != null)
{
c.style.textDecoration = "underline";
c.style.color = "blue";
c.style.cursor = "hand";
c.disabled = false;
c.ondblclick = function()
{
window.open(Xrm.Page.getAttribute(fieldid).getValue());
};
}
}
function void ShowHidePhoneNumbers()
{
var contact = Xrm.Page.getControl("To");
var regarding = Xrm.Page.getControl("Regarding");
if (contact != null)
window.alert("Contact is not null");
if(regarding != null)
window.alert("Regarding is not null");
}
I am calling both on "onLoad" of new Phone Call Activity form.
I get "Error: the value of property 'ConvertRecordingFieldToLink' is null or undefined, not a Function object".
I get the same error even if disable any one function.
Any suggestions?
Thanks