使用英语阅读

通过


IVsDropdownBarClient.GetEntryText Method

Returns the text for a combo entry.

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

Syntax

int GetEntryText(
    int iCombo,
    int iIndex,
    out string ppszText
)

Parameters

  • iCombo
    Type: System.Int32
    [in] The drop-down bar/Window combo.
  • ppszText
    Type: System.String%
    [out] String containing the text.

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 textmgr.idl:

HRESULT IVsDropdownBarClient::GetEntryText(
   [in] long iCombo,
   [in] long iIndex,
   [out] WCHAR **ppszText
);

备注

The text buffer returned in ppszText is typically created by the IVsDropdownBarClient object and the buffer must persist for the life of the IVsDropdownBarClient object.

If you are implementing this interface in managed code and you need to have the string disposed of by the caller, implement the IVsCoTaskMemFreeMyStrings interface on the IVsDropdownBarClient interface.

.NET Framework Security

See Also

Reference

IVsDropdownBarClient Interface

Microsoft.VisualStudio.TextManager.Interop Namespace