An easier way to hide or show a certain field in CRM

Simply use the function below:

// Shows or hides a certain field
function HandleField(field, display) {
document.getElementById(field+”_c”).style.display = display;
document.getElementById(field+”_d”).style.display = display;

/* Calling */
HandleField(“fieldid”, “inline”); // show inline
HandleField(“fieldid”, “block”); // show block
HandleField(“fieldid”, “none”); // hide

Leave a comment

Your email address will not be published. Required fields are marked *