更新 : 2007 年 11 月
VSWebSite オブジェクトの References プロパティのイベントを表します。このクラスの機能にアクセスするには、AssemblyReferencesEvents プロパティから取得した AssemblyReferencesEvents オブジェクトを使用します。このクラスからインスタンス化しないでください。
名前空間 : VsWebSite
アセンブリ : VsWebSite.Interop (VsWebSite.Interop.dll 内)
構文
'宣言
<GuidAttribute("F11526E7-4102-4070-9B60-BD4F5CD3006B")> _
<ClassInterfaceAttribute()> _
Public Class AssemblyReferencesEventsClass _
Implements _AssemblyReferencesEvents, AssemblyReferencesEvents, _dispAssemblyReferencesEvents_Event
'使用
Dim instance As AssemblyReferencesEventsClass
[GuidAttribute("F11526E7-4102-4070-9B60-BD4F5CD3006B")]
[ClassInterfaceAttribute()]
public class AssemblyReferencesEventsClass : _AssemblyReferencesEvents,
AssemblyReferencesEvents, _dispAssemblyReferencesEvents_Event
[GuidAttribute(L"F11526E7-4102-4070-9B60-BD4F5CD3006B")]
[ClassInterfaceAttribute()]
public ref class AssemblyReferencesEventsClass : _AssemblyReferencesEvents,
AssemblyReferencesEvents, _dispAssemblyReferencesEvents_Event
public class AssemblyReferencesEventsClass implements _AssemblyReferencesEvents, AssemblyReferencesEvents, _dispAssemblyReferencesEvents_Event
解説
このクラスには、AssemblyReferencesEvents プロパティから取得できる AssemblyReferencesEvents インターフェイスを通じてアクセスします。
![]() |
---|
このクラスで提供される機能は、Visual Studio 2005 以降のバージョンの Visual Studio で使用できます。Visual Web Developer Express Edition では使用できません。 |
例
次に示すマクロ コードの例は、DTE (Development Tools Extensibility) オブジェクトを使用して現在の VSWebSite オブジェクトへの参照を作成する方法、および、イベントをサブスクライブする方法を示しています。このサンプルは、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
継承階層
System.Object
VsWebSite.AssemblyReferencesEventsClass
スレッド セーフ
この型のすべてのパブリック static (Visual Basic では Shared) メンバは、スレッド セーフです。インスタンス メンバの場合は、スレッド セーフであるとは限りません。
参照
参照
AssemblyReferencesEventsClass メンバ