I know how to hide a field input control based on a value from another field in Javascript onload , cannot figure out how to hide the tooltip and label for the same scenario.
This Hides the input field
var ctrlfldsales = Runner.getControl(pageid, 'fldsales');
var ctrlfsm_email = Runner.getControl(pageid, 'fsm_email');
var ctrlManager = Runner.getControl(pageid, 'Manager');
var ctrlteam = Runner.getControl(pageid, 'team');
var ctrlflddivision = Runner.getControl(pageid, 'flddivision');
ctrlfldsales.on('change', function(e){
if (this.getValue() == 'SalesRep'){
ctrlfsm_email.show();
ctrlManager.hide();
ctrlteam.show();
ctrlflddivision.show();
}else{
if (this.getValue() == 'FSM') {
ctrlfsm_email.show();
ctrlManager.show();
ctrlteam.show();
ctrlflddivision.show();
} else {
if(this.getValue() == 'Other') {
ctrlfsm_email.hide();
ctrlManager.hide();
ctrlteam.hide();
ctrlflddivision.hide();
}
}
}
}
);
I know pageObj.hidefield works for field and label but when I add it to this code nothing hides.
.
Any Ideas?