共用方式為


IVsDropdownBar.Attach 方法

[視窗] 和 [下拉式組合,會建立並設定 [鉛版] 列和其用戶端之間的連結。

命名空間:  Microsoft.VisualStudio.TextManager.Interop
組件:  Microsoft.VisualStudio.TextManager.Interop (在 Microsoft.VisualStudio.TextManager.Interop.dll 中)

語法

'宣告
Function Attach ( _
    hwndParent As IntPtr, _
    cCombos As Integer, _
    pClient As IVsDropdownBarClient _
) As Integer
int Attach(
    IntPtr hwndParent,
    int cCombos,
    IVsDropdownBarClient pClient
)
int Attach(
    [InAttribute] IntPtr hwndParent, 
    [InAttribute] int cCombos, 
    [InAttribute] IVsDropdownBarClient^ pClient
)
abstract Attach : 
        hwndParent:IntPtr * 
        cCombos:int * 
        pClient:IVsDropdownBarClient -> int
function Attach(
    hwndParent : IntPtr, 
    cCombos : int, 
    pClient : IVsDropdownBarClient
) : int

參數

  • hwndParent
    類型:IntPtr

    [in]父視窗的控制代碼。

  • cCombos
    類型:Int32

    [in]下拉式列 / 視窗組合。

傳回值

類型:Int32
如果此方法將會成功,則會傳回S_OK。如果失敗,它就會傳回錯誤碼。

備註

Attach由呼叫AddDropdownBarAttach建立視窗和 [下拉式清單的組合,並設定 [下拉列之間的連結,其IVsDropdownBarClient。 不要呼叫這個函式,除非您正在略過IVsDropdownBarManager

COM 簽章

從 textmgr.idl:

HRESULT IVsDropdownBar::Attach(
   [in] HWND hwndParent,
   [in] long cCombos,
   [in] IVsDropdownBarClient *pClient
);

.NET Framework 安全性

請參閱

參考

IVsDropdownBar 介面

Microsoft.VisualStudio.TextManager.Interop 命名空間