ProvideMenuResourceAttribute Constructor (Int16, Int32)
This constructor creates a new ProvideMenuResourceAttribute object with the given resource ID and version number.
Namespace: Microsoft.VisualStudio.Shell
Assemblies: Microsoft.VisualStudio.Shell.10.0 (in Microsoft.VisualStudio.Shell.10.0.dll)
Microsoft.VisualStudio.Shell.9.0 (in Microsoft.VisualStudio.Shell.9.0.dll)
Microsoft.VisualStudio.Shell (in Microsoft.VisualStudio.Shell.dll)
Syntax
‘선언
Public Sub New ( _
resourceID As Short, _
version As Integer _
)
‘사용 방법
Dim resourceID As Short
Dim version As Integer
Dim instance As New ProvideMenuResourceAttribute(resourceID, _
version)
public ProvideMenuResourceAttribute(
short resourceID,
int version
)
public:
ProvideMenuResourceAttribute(
short resourceID,
int version
)
new :
resourceID:int16 *
version:int -> ProvideMenuResourceAttribute
public function ProvideMenuResourceAttribute(
resourceID : short,
version : int
)
Parameters
- resourceID
Type: System.Int16
The ID of the menu resource. It must match the resource ID used in both the satellite (resource-only) DLL and the Command Table Configuration (.Ctc) Files.
- version
Type: System.Int32
The version number of the menu resource.
Remarks
The C# language automatically appends the word "Attribute" to the name of any attribute class. In C# code, refer to this attribute as ProvideMenuResource.
Examples
The following C# code applies the ProvideMenuResource attribute to a VSPackage named MyVSPackage.
using Microsoft.VisualStudio.VSIP;
using MSVSIP = Microsoft.VisualStudio.VSIP;
[MSVSIP.Helper.ProvideMenuResource(1000, 1)]
public class MyVSPackage : MSVSIP.Helper.Package {}
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
ProvideMenuResourceAttribute Class
ProvideMenuResourceAttribute Members