Exportar (0) Imprimir
Expandir todo

IVsProfferCommands4.AddNamedCommand3 Method

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

int AddNamedCommand3(
	ref Guid pguidPackage,
	ref Guid pguidCmdGroup,
	string pszCmdNameCanonical,
	out uint pdwCmdId,
	string pszCmdNameLocalized,
	string pszBtnText,
	string pszCmdTooltip,
	Object punkImage,
	uint dwCmdFlagsDefault,
	uint cUIContexts,
	Guid[] rgguidUIContexts,
	uint dwUIElementType
)

Parameters

pguidPackage
Type: System.Guid%
[in] The package GUID. Use null for addins.
pguidCmdGroup
Type: System.Guid%
[in] The GUID for the group to receive the new command. Use GUID_Macro or GUID_AddIn defined in vbapkg.idl.
pszCmdNameCanonical
Type: System.String
[in] The full name of the command.
pdwCmdId
Type: System.UInt32%
[out] The ID for the new command.
pszCmdNameLocalized
Type: System.String
[in] A localized version of the string. May be null.
pszBtnText
Type: System.String
[in] The text to display on a button. Use null if the added command isn't a button.
pszCmdTooltip
Type: System.String
[in] The ToolTip text to display. May be null.
punkImage
Type: System.Object
[in] The image. This can be a Bitmap, and Icon, or an IPicture.
dwCmdFlagsDefault
Type: System.UInt32
[in] Use zero (0) for the default values to make the command active and visible.
cUIContexts
Type: System.UInt32
[in] The number of contexts pointed to by the rgguidUIContexts parameter.
rgguidUIContexts
Type: System.Guid[]
[in] An array of GUIDs for the user interface contexts indicating options for displaying the command. For more information, see the UIContext_ members of VSConstants.
dwUIElementType
Type: System.UInt32
[in] A value from the vsCommandControlType enumeration.

Return Value

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

Mostrar:
© 2014 Microsoft