RibbonManager Constructor
Initializes a new instance of the RibbonManager class.
Namespace: Microsoft.Office.Tools.Ribbon
Assembly: Microsoft.Office.Tools.Common.v9.0 (in Microsoft.Office.Tools.Common.v9.0.dll)
Syntax
'Declaration
Public Sub New ( _
ParamArray ribbons As OfficeRibbon() _
)
'Usage
Dim ribbons As OfficeRibbon()
Dim instance As New RibbonManager(ribbons)
public RibbonManager(
params OfficeRibbon[] ribbons
)
Parameters
- ribbons
Type: array<Microsoft.Office.Tools.Ribbon.OfficeRibbon[]
The array of OfficeRibbon objects in your project that you want to display at run time.
Remarks
Create a new RibbonManager object if you have multiple Ribbons in your project, and you want to specify which one is displayed at run time. To do this, override the CreateRibbonExtensibilityObject method of the ThisAddIn, ThisWorkbook, or ThisDocument class, and return a new RibbonManager object that contains the OfficeRibbon object (or objects) that you want to display. For more information, see Ribbon Overview.
For Word, Excel, and PowerPoint, you typically pass a single OfficeRibbon object to this constructor, because these applications display only one Ribbon.
For Outlook, you can pass multiple OfficeRibbon objects to this constructor, because Outlook can display a different Ribbon for each type of Inspector. For example, you can display one Ribbon for mail items, and a different Ribbon for tasks.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
Microsoft.Office.Tools.Ribbon Namespace