KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Programmatically prevent scrolling in View Pro dashboard
PRODUCT: 4D View Pro | VERSION: 20 | PLATFORM: Mac & Win
Published On: March 11, 2024

When creating a dashboard from a 4D View Pro area, the end user should be prevented from scrolling away from the main view port, so that the contents of the dashboard are always in view. To do this programmatically, freeze the pane area that contains the rows and columns where the dashboard is displayed, like below:

$pane_o:=New object
$pane_o.columnCount:=15
$pane_o.rowCount:=30
VP SET FROZEN PANES("ViewProArea"; $pane_o)

In the example code above, the dashboard would have a size of 15 columns wide and 30 rows long. When VP SET FROZEN PANES is called on the pane object, it effectively prevents scrolling away from the dashboard.