Wednesday, February 08, 2012

CRM 2011: Creating a Network Path Text Control for Microsoft Dynamics CRM 2011

Following approach is a little bit unsupported so be careful using it.

Create JavaScript webresource, put in it following code, call OnLoad method during loading of form of your entity:

function OnLoad()
{
Transform("new_name");
}

function Transform(fieldid)
{
var c = document.getElementById(fieldid);
if (c == null)
return;

c.style.textDecoration = "underline";
c.style.color = "blue";
c.style.cursor = "hand";
c.ondblclick = function()
{
window.open(Xrm.Page.getAttribute(fieldid).getValue());
};
}


Field has to be simple text type. Replace new_name with field you want to transform. Result for my case: