This topic has not yet been rated - Rate this topic

Application.RegisterRibbonX Method (Visio)

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

Version Information

Version Added: Visio 2010

Syntax

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

expression A variable that represents an Application object.

Parameters

Name Required/Optional Data Type Description

SourceAddOn

Required

IRibbonExtensibilty

The add-on to register.

TargetDocument

Required

Document

The document that uses the custom UI.

TargetModes

Required

VisRibbonXModes

The modes in which the custom UI should be visible. See Remarks for possible values.

FriendlyName

Required

String

The 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.

Name Value Description

visRxModeNone

0

Display the custom UI when no documents are open.

visRxModeDrawing

1

Display the custom UI in Drawing mode.

visRxModeStencil

2

Display the custom UI in Stencil mode.

visRxModePrintPreview

4

Display the custom UI in Print Preview mode.

If FriendlyName is null, the method fails.

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.