In this below script,Get current Item ID in Editform or Display Form In SharePoint list Default forms
function GetID()
{
var getid = new RegExp("[\\?&]"+"ID"+"=([^&#]*)");
value = getid.exec(window.location.href);
alert(value[1]);
}
_spBodyOnLoadFunctionNames.push("GetID");
{
var getid = new RegExp("[\\?&]"+"ID"+"=([^&#]*)");
value = getid.exec(window.location.href);
alert(value[1]);
}
_spBodyOnLoadFunctionNames.push("GetID");
No comments:
Post a Comment