I am using below cde but its not working pls some one help me.
function getFieldListFromTab(tabId)
{
var fieldList = new Array();
var tab = Xrm.Page.ui.tabs.get(tabId);
tab.sections.forEach(function (section, sectionIndex)
{
section.controls.forEach(function (control, controlIndex)
{
var attribute = control.getAttribute();
if (attribute != null)
{
fieldList.push(attribute.getName());
}
});
});
return fieldList;
}





