次の方法で共有


IVsUIShell.SetMRUComboText Method

Adds information to a combo box list.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)

Syntax

'宣言
Function SetMRUComboText ( _
    ByRef pguidCmdGroup As Guid, _
    dwCmdID As UInteger, _
    lpszText As String, _
    fAddToList As Integer _
) As Integer
'使用
Dim instance As IVsUIShell
Dim pguidCmdGroup As Guid
Dim dwCmdID As UInteger
Dim lpszText As String
Dim fAddToList As Integer
Dim returnValue As Integer

returnValue = instance.SetMRUComboText(pguidCmdGroup, _
    dwCmdID, lpszText, fAddToList)
int SetMRUComboText(
    ref Guid pguidCmdGroup,
    uint dwCmdID,
    string lpszText,
    int fAddToList
)
int SetMRUComboText(
    [InAttribute] Guid% pguidCmdGroup, 
    [InAttribute] unsigned int dwCmdID, 
    [InAttribute] String^ lpszText, 
    [InAttribute] int fAddToList
)
abstract SetMRUComboText : 
        pguidCmdGroup:Guid byref * 
        dwCmdID:uint32 * 
        lpszText:string * 
        fAddToList:int -> int 
function SetMRUComboText(
    pguidCmdGroup : Guid, 
    dwCmdID : uint, 
    lpszText : String, 
    fAddToList : int
) : int

Parameters

  • pguidCmdGroup
    Type: System.Guid%
    [in] Unique identifier of the command group; can be nulla null reference (Nothing in Visual Basic) to specify the standard group. All the commands that are passed in the nCmdID must belong to the group specified by pguidCmdGroup.
  • dwCmdID
    Type: System.UInt32
    [in] The command to be executed. This command must belong to the group specified with pguidCmdGroup.
  • lpszText
    Type: System.String
    [in] Specifies the text to place in the combo box list.
  • fAddToList
    Type: System.Int32
    [in] If true, then the text in lpszText is added to the combo box.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsUIShell::SetMRUComboText(
   [in] const GUID * pguidCmdGroup,
   [in] DWORD dwCmdId,
   [in] LPSTR lpszText,
   [in] BOOL fAddToList
);

Use SetMRUComboTextW in place of this method.

.NET Framework Security

See Also

Reference

IVsUIShell Interface

IVsUIShell Members

Microsoft.VisualStudio.Shell.Interop Namespace