Wednesday, 6 January 2010

Show / Hide field / label / line / section / tab

from http://jianwang.blogspot.com/2007/11/crm-how-to-hide-field-label-line.html

/*hide field only*/
crmForm.all.field.style.display = 'none';

/*hide field and this field's label*/
crmForm.all.field.style.display = 'none';
crmForm.all.field_c.style.display = 'none';

/*hide field and the whole line which contains this field*/
crmForm.all.field.parentElement.parentElement.style.display = 'none';

/*hide field and the section which contains this field*/
crmForm.all.field.parentElement.parentElement.parentElement.style.display = 'none';

/*hide a tab(tab number comes from 0)*/
crmForm.all.tab2Tab.style.display = 'none';

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home