IVsComponentSelectorDlg2.ComponentSelectorDlg2 方法

显示 选择组件对话框 并返回所选元素。

命名空间:  Microsoft.VisualStudio.Shell.Interop
程序集:  Microsoft.VisualStudio.Shell.Interop.8.0(在 Microsoft.VisualStudio.Shell.Interop.8.0.dll 中)

语法

声明
Function ComponentSelectorDlg2 ( _
    grfFlags As UInteger, _
    pUser As IVsComponentUser, _
    cComponents As UInteger, _
    rgpcsdComponents As IntPtr(), _
    lpszDlgTitle As String, _
    lpszHelpTopic As String, _
    <OutAttribute> ByRef pxDlgSize As UInteger, _
    <OutAttribute> ByRef pyDlgSize As UInteger, _
    cTabInitializers As UInteger, _
    rgcstiTabInitializers As VSCOMPONENTSELECTORTABINIT(), _
    <OutAttribute> ByRef pguidStartOnThisTab As Guid, _
    pszBrowseFilters As String, _
    <OutAttribute> ByRef pbstrBrowseLocation As String _
) As Integer
int ComponentSelectorDlg2(
    uint grfFlags,
    IVsComponentUser pUser,
    uint cComponents,
    IntPtr[] rgpcsdComponents,
    string lpszDlgTitle,
    string lpszHelpTopic,
    out uint pxDlgSize,
    out uint pyDlgSize,
    uint cTabInitializers,
    VSCOMPONENTSELECTORTABINIT[] rgcstiTabInitializers,
    out Guid pguidStartOnThisTab,
    string pszBrowseFilters,
    out string pbstrBrowseLocation
)

参数

  • grfFlags
    类型:System.UInt32
    [in] 从 VSCOMPSELFLAGS2 枚举数执行的组件选择标志。
  • cComponents
    类型:System.UInt32
    [in] 元素数。 rgpcsdComponents 数组。
  • rgpcsdComponents
    类型:array<System.IntPtr[]
    [in] 所选元素的 Prepopulation。可以为 NULL。用户能够从列表中移除这些元素中的任何一个。
  • lpszDlgTitle
    类型:System.String
    [in] 对话框声明 (nullnull 引用(在 Visual Basic 中为 Nothing) == “select 元素”)。
  • lpszHelpTopic
    类型:System.String
    [in] F1 帮助主题 (nullnull 引用(在 Visual Basic 中为 Nothing) == “VS.ComponentPicker”)
  • pxDlgSize
    类型:System.UInt32%
    [in, out] 使用默认值 0。
  • pyDlgSize
    类型:System.UInt32%
    [in, out] 使用默认值 0。
  • cTabInitializers
    类型:System.UInt32
    [in] 选项的数字。
  • pguidStartOnThisTab
    类型:System.Guid%
    [in, out] 显示对话框时要使用的选项启动
  • pszBrowseFilters
    类型:System.String
    [in] 列出了筛选使用 " browse…”对话框
  • pbstrBrowseLocation
    类型:System.String%
    [in, out] (初始/返回值) 开始 “浏览的内容…”对话框

返回值

类型:System.Int32
如果方法成功,则返回 S_OK。如果失败,它会返回一个错误代码。

备注

COM 签名

从 vsshell80.idl:

HRESULT IVsComponentSelectorDlg2::ComponentSelectorDlg2(
   [in] VSCOMPSELFLAGS2 grfFlags, 
   [in] IVsComponentUser *pUser, 
   [in] ULONG cComponents, 
   [in, size_is(cComponents)] PVSCOMPONENTSELECTORDATA rgpcsdComponents[], 
   [in] LPCOLESTR lpszDlgTitle, 
   [in] LPCOLESTR lpszHelpTopic, 
   [in, out] ULONG * pxDlgSize, 
   [in, out] ULONG * pyDlgSize, 
   [in] ULONG cTabInitializers, 
   [in, size_is(cTabInitializers)] VSCOMPONENTSELECTORTABINIT rgcstiTabInitializers[], 
   [in, out] GUID * pguidStartOnThisTab, 
   [in] LPCOLESTR pszBrowseFilters, 
   [in, out] BSTR *pbstrBrowseLocation
);

.NET Framework 安全性

请参见

参考

IVsComponentSelectorDlg2 接口

Microsoft.VisualStudio.Shell.Interop 命名空间