共用方式為


AddIn.Connected 屬性

取得或設定值,指出是否已載入及連接增益集。

命名空間:  EnvDTE
組件:  EnvDTE (在 EnvDTE.dll 中)

語法

'宣告
Property Connected As Boolean
bool Connected { get; set; }
property bool Connected {
    bool get ();
    void set (bool value);
}
abstract Connected : bool with get, set
function get Connected () : boolean
function set Connected (value : boolean)

屬性值

型別:System.Boolean
指示是否已載入及連接增益集的布林值。

備註

如果已載入與連接增益集,則會傳回 true,否則為 false。

範例

Sub ConnectedExample()
   ' Set object references.
   Dim addincoll As AddIns
   Dim addinobj As AddIn
   
   addincoll = DTE.AddIns
   addinobj = addincoll.Item(1)

   ' Connect the add-in if it is not already connected
   ' and list its SatelliteDLLPath and Guid.
   If addinobj.Connected = False Then
      addinobj.Connected = True
   End If
   MsgBox("Satellite DLL Path: " & addinobj.SatelliteDllPath)
   MsgBox("DLL GUID: " & addinobj.Guid)
End Sub

.NET Framework 安全性

請參閱

參考

AddIn 介面

EnvDTE 命名空間