Dynamic Field Visibility

Dynamic Field Visibility in Business Central

Info

Notes based on BC27

How to Set Field Visibility

The field visibility can be set using a boolean global variable. The variable might be set in OnOpenPage or OnAfterGetRecord triggers:

Setting visibility with global variable Setting visibility with global variable

What Doesn’t Work for Setting Visibility

It is not possible to set visibility using:

  1. Procedure Attempting to use procedure for visibility Attempting to use procedure for visibility

  2. Array Attempting to use array for visibility Attempting to use array for visibility

  3. List Attempting to use list for visibility Attempting to use list for visibility

  4. Field from the Page Table

Warning

It compiles but throws a runtime error

Using field from page table - first image Using field from page table - first image Using field from page table - second image Using field from page table - second image