Partager via


Events2.CommandBarEvents, propriété (Object)

Obtient un objet fournissant des événements déclenchés lorsque l'objet CommandBarControl fourni fait l'objet d'un clic.

Espace de noms :  EnvDTE80
Assembly :  EnvDTE80 (dans EnvDTE80.dll)

Syntaxe

'Déclaration
ReadOnly Property CommandBarEvents ( _
    CommandBarControl As Object _
) As Object
    Get
Object this[
    Object CommandBarControl
] { get; }
property Object^ CommandBarEvents[[InAttribute] Object^ CommandBarControl] {
    Object^ get ([InAttribute] Object^ CommandBarControl);
}
abstract CommandBarEvents : Object
JScript ne prend pas en charge les propriétés indexées.

Paramètres

  • CommandBarControl
    Type : System.Object
    Obligatoire.Contrôle CommandBar qui provoque le déclenchement de l'événement.

Valeur de propriété

Type : System.Object
Objet CommandBarEvents.

Implémentations

Events.CommandBarEvents[Object]

Notes

Un complément utilise la propriété CommandBarEvents pour connecter un événement avec un clic d'objet Microsoft.VisualStudio.CommandBars.CommandBarControl, ou pour se connecter à l'événement Click de n'importe quel membre de la collection Microsoft.VisualStudio.CommandBars.CommandBarControls.

Le complément doit définir la propriété OnAction à une valeur de chaîne. Il peut définir cette valeur après l'appel de la propriété CommandBarEvents, et peut la réinitialiser en une chaîne vide, qui déconnecte l'événement. Si un complément crée un contrôle et n'affecte pas une valeur de chaîne valide à la propriété OnAction, aucun événement n'est déclenché sur l'objet événement retourné par la propriété CommandBarEvents.

Sécurité .NET Framework

Voir aussi

Référence

Events2 Interface

CommandBarEvents, surcharge

EnvDTE80, espace de noms