I have a business process flow that has 4 stages all from the same table. And i have 3 forms all showing the same BPF. I am using javascript to hide them when the form is on load. It works when the form is loaded and nothing is filled in yet. but when i fill in some of the fields in the form and hit save, if I refresh the form or if I go back into the record, the field is visible again. Here is the code :
if(formContext.getControl("header_process_da_vpstatus") != null)
{
formContext.getControl("header_process_da_vpstatus").setVisible(false);
}
I tried putting this on the form save event, but it still doesnt work.
No i do not have any business rules regarding that field. I just added formContext.data.addOnLoad(functionToRun) and now it runs and hides the field on form initial load and after saving. However when I hit the refresh icon on the top of the form or if I navigate to a different form and go back, it does not trigger the function anymore and the field becomes unhidden. Also if I go out of the form and into the table view, and click on the record, it does not trigger the function and therefore the field remains unhidden.
How can i trigger the function in these three scenarios? I currently have the javascript added to the Form Onload event.
Hi bp3378,
Do you have any activate business rule to show that field?
If so, please deactivate that business rule to have a try.
André Arnaud de Cal...
291,965
Super User 2025 Season 1
Martin Dráb
230,817
Most Valuable Professional
nmaenpaa
101,156