SharepointEnabled: Boolean ;
The SharepointEnabled property determines whether the Discuss menu item is available.
Property value can be set from JSON or using the setSharepointEnabled method, property value is returned by the getSharepointEnabled method.
To execute the example, the HTML page must contain the ExpressBox component named expressBox (see Example of Creating the ExpressBox Component). Get main menu:
// Get instance of main menu rib = expressBox.getRibbonView(); menu = rib.getMainMenu(); // Check whether the Discuss in SharePoint menu item is available console.debug(menu.getSharepointEnabled() ? "The Discuss menu item is available" : "The Discuss menu item is not available"); // Set new display mode for menu items menu.setViewMode(PP.Mb.Ui.MainMenuViewMode.ReadOnly);
After executing the example the console displays information about availability of the Discuss in SharePoint menu item, menu item display mode will correspond to the Read Only mode, the Save menu item is not available.
See also: