Table of contents
TOC
Collapse the table of content
Expand the table of content

Application.RegisterRibbonX Method (Visio)

office 365 dev account|Last Updated: 6/12/2017
|
1 Contributor

Registers the IRibbonExtensibility interface that is implemented by the specified add-on to populate the custom user interface (UI).

Syntax

expression . RegisterRibbonX( SourceAddOn , TargetDocument , TargetModes , FriendlyName )

expression A variable that represents an Application object.

Parameters

NameRequired/OptionalData TypeDescription
SourceAddOnRequiredIRibbonExtensibiltyThe add-on to register.
TargetDocumentRequiredDocumentThe document that uses the custom UI.
TargetModesRequiredVisRibbonXModesThe modes in which the custom UI should be visible. See Remarks for possible values.
FriendlyNameRequiredStringThe name to associate with the UI items and errors that originate in the add-on.

Return Value

Nothing

Remarks

If TargetDocument is null, the custom UI is defined at the level of the application. Otherwise, Microsoft Visio binds the visibility of the custom UI to the specified document. The UI does not appear in conjunction with any other document.

TargetModes can be one or more of the following VisRibbonXModes constants.

NameValueDescription
visRxModeNone0Display the custom UI when no documents are open.
visRxModeDrawing1Display the custom UI in Drawing mode.
visRxModeStencil2Display the custom UI in Stencil mode.
visRxModePrintPreview4Display the custom UI in Print Preview mode.

If FriendlyName is null, the method fails.

© 2017 Microsoft