# WebPages HMI $ Functions

The HMI $ functions provide flexibility and additional functionality compared to strictly using a tag and binding associations, and are designed to interact with a job while online, via a Button element's OnClicked script point, for example.

The WebPages HMI $ functions are "static" HMI functions, and are used to programmatically interact with the entire WebPages infrastructure, versus being associated with a single element or WebPage.

Most of these functions are not asynchronous (that is, they are evaluated in the web browser, not on the vision system), however, the functions associated with the WebPage (such as GetPageTitle, GetPageWidth, etc.) should be treated as though they are asynchronous to handle their return values.

Several functions return a Promise object because JavaScript is asynchronous, and callbacks (that is, Promises) must be used to use the returned value.

    $HMI.CloseDialogPage() : Void
Returns | Void
Arguments | N/A
Description | Closes the active dialog page.

    $HMI.Logout() : Void
Returns | Void
Arguments | N/A
Description | Logs out of the HMI webpage.

    $HMI.ShowLogin() : Boolean
Returns | Boolean
Arguments | N/A
Description | Shows the login process.