Anveo Mobile App / Best Practices / The Home Button

The Home Button

To use the advantages of a home button without having one, you can proceed as follows. The descriped process of returning to the main menu is controlled by a Global System State.

Required Objects

ACF Global Variable

A virtual table to store values beyond the local scope. The Name of the variable (code 20) is used as the key. To make the different data types easy to use, it contains a separate field for all (common) data types.


Create a library with the following three functions required for the process:

The function goHome() starts the process by adding a global variable “HOME”.

The goingHome() function returns whether the process is running, i.e. the variable home exists.

The function goneHome() ends the process by deleting the variable home.

Recommended application

The application of this process is not primarily designed for system-wide integration. The typical use case is a workflow that requires a longer click path and ends with many open pages.
At the end of the click path, a menu entry/promoted button is desired that allows you to return to the main menu. Here a script is deposited, which executes the function goHome().

All pages on the click path must be prepared for the process. For this the function goingHome() is executed in the OnAfterGetRecord trigger. If this function returns true, the page can be closed and, if necessary, the further execution of the trigger can be prevented by a return.

In the OnOpenMenu trigger, the process is terminated with the goneHome() function.