I want to show or hide a few fields based on the value of another field. I have it working correctly when the field value is changed by using client side events for that field.
{
"change": function(e) {
if (this.value == "XX") {
$(this).fields("fieldA").visible(true);
$(this).fields("fieldB").visible(false);
} else if (this.value == "YY") {
$(this).fields("fieldA").visible(false);
$(this).fields("fieldB").visible(true);
}
}
However, I don’t know how to hide the fields initially on the Edit page based on the value before the change.