PageToolbar

Purpose

PageToolbar is a client-side JavaScript object that represents the page toolbar on an application page. A page toolbar contains buttons. Use the PageContext function getPageToolbar() to access the PageToolbar object.

Note:

The methods in this section apply to the new UI, not the classic UI. Most Platform tenants are using the new UI. However, tenants on older Private Cloud installations might still be using the classic UI.

These methods are not supported in portals.

Interface

PageToolbar supports the following functions:

  • getItemByName(itemName) — Returns a jQuery object representing the button with the specified name
  • getItemsByClassName(className) — Returns a set of jQuery objects representing all buttons in the page toolbar with the CSS class identifier as specified by the argument className. Currently, all page toolbar buttons have CSS class identifier "marker-pageToolbar-action".
  • getKendoConfig() — Returns the Kendo Toolbar configuration object for the page toolbar
  • getNode() — Returns a jQuery object representing the page toolbar
  • showOrHideItem(itemName, show) — Shows or hides the button with the specified name. If the show parameter is true, shows the button. If the show parameter is false, hides the button.

Examples

The following example returns a set of jQuery objects for all of the buttons in the page toolbar:

rbf_getPageContext().getPageToolbar().getItemsByClassName("marker-pageToolbar-action");

The following example hides the button with the specified name:

rbf_getPageContext().getPageToolbar().showOrHideItem("Button_1", false);