AddIns 인터페이스
업데이트: 2007년 11월
DTE.AddIns인 경우 추가 기능 관리자 대화 상자에 표시된 모든 추가 기능을 포함하고 ProjectSolution.AddIns인 경우 특정 솔루션에서 로드한 모든 추가 기능을 포함합니다.
네임스페이스: EnvDTE
어셈블리: EnvDTE(EnvDTE.dll)
구문
<GuidAttribute("50590801-D13E-4404-80C2-5CA30A4D0EE8")> _
Public Interface AddIns _
Implements IEnumerable
Dim instance As AddIns
[GuidAttribute("50590801-D13E-4404-80C2-5CA30A4D0EE8")]
public interface AddIns : IEnumerable
[GuidAttribute(L"50590801-D13E-4404-80C2-5CA30A4D0EE8")]
public interface class AddIns : IEnumerable
public interface AddIns extends IEnumerable
설명
AddIn 개체는 특정 추가 기능에 대한 정보를 다른 추가 기능에 제공합니다. 또한 AddIn 개체는 등록된 추가 기능만 나타낼 수 있습니다.
IDTExtensibility2 인터페이스에는 해당 추가 기능이 솔루션 추가 기능이 아닌 경우 AddIns 컬렉션이 업데이트될 때 발생하는 OnAddInsUpdate 메서드가 포함되어 있습니다.
예제
Sub AddInsExample()
' For this example to work correctly, there should be an add-in
' available in the Visual Studio environment.
' Set object references.
Dim addincoll As AddIns
Dim addinobj As AddIn
' Register an add-in, check DTE add-in count before and after the
' update.
addincoll = DTE.AddIns
MsgBox("AddIns collection parent name: " & addincoll.Parent.Name)
MsgBox("Number of Add-ins: " & addincoll.Count)
' NOTE: Use regsvr32 for Visual C++, regasm for Visual Basic
' and Visual C#. Also, the pathname used below is an example only.
Shell("regasm F:\AddIns\RegExplore\Debug\regexplore.dll")
addincoll.Update()
MsgBox("Number of Add-ins: " & addincoll.Count)
addinobj = addincoll.Item(1)
End Sub