Compartir a través de


AssemblyReferencesEvents (Interfaz)

Actualización: noviembre 2007

Representa los eventos de la propiedad References de un objeto VSWebSite. Utilice esta clase para tener acceso a la funcionalidad proporcionada por AssemblyReferencesEventsClass.

Espacio de nombres:  VsWebSite
Ensamblado:  VsWebSite.Interop (en VsWebSite.Interop.dll)

Sintaxis

<GuidAttribute("E5E56972-0CFE-49B7-9EFB-923613FDA978")> _
Public Interface AssemblyReferencesEvents _
    Implements _AssemblyReferencesEvents, _dispAssemblyReferencesEvents_Event

Dim instance As AssemblyReferencesEvents
[GuidAttribute("E5E56972-0CFE-49B7-9EFB-923613FDA978")]
public interface AssemblyReferencesEvents : _AssemblyReferencesEvents, 
    _dispAssemblyReferencesEvents_Event
[GuidAttribute(L"E5E56972-0CFE-49B7-9EFB-923613FDA978")]
public interface class AssemblyReferencesEvents : _AssemblyReferencesEvents, 
    _dispAssemblyReferencesEvents_Event
public interface AssemblyReferencesEvents extends _AssemblyReferencesEvents, _dispAssemblyReferencesEvents_Event

Comentarios

Utilice la propiedad AssemblyReferencesEvents para obtener esta interfaz al objeto AssemblyReferencesEventsClass.

Nota:

La funcionalidad proporcionada por esta clase está disponible en todas las versiones de Visual Studio a partir de Visual Studio 2005. No está disponible en Visual Web Developer Express.

Ejemplos

El siguiente ejemplo de código de macro muestra cómo crear una referencia al objeto VSWebSite actual a través del entorno en tiempo de diseño (DTE) y cómo suscribirse a un evento. Este ejemplo forma parte de un ejemplo de código más extenso referente a VSWebSiteEvents.

' Initialize the VsWebSite and the Events
Sub InitAssemblyRefsEvents()
    ' Get a reference to the first Web site 
    ' in the current solution
    Dim ws As VsWebSite.VSWebSite = _
        DTE.Solution.Projects.Item(1).Object

    ' Attach the Web site events to module events
    AssemblyRefsEvents = _
        ws.VSWebSiteEvents.AssemblyReferencesEvents
End Sub
' Declare the event
' The macro IDE requires the attribute 
' in order to trap the events
<System.ContextStaticAttribute()> _
Public WithEvents AssemblyRefsEvents As _
    VsWebSite.AssemblyReferencesEvents

Vea también

Referencia

AssemblyReferencesEvents (Miembros)

VsWebSite (Espacio de nombres)

DTE

VSWebSite

VSWebSiteEvents

VSWebSiteEvents

AssemblyReferencesEvents

AssemblyReferencesEventsClass

Otros recursos

Establecer referencias a los ensamblados de automatización y al objeto DTE2

Cómo: Controlar eventos en una macro