RibbonButton 建構函式 (String, ICommand, ICommandId, Object, ImageSource, ImageSource)
適用於版本2
初始化 RibbonButton 類別的新執行個體。
命名空間: Microsoft.WebMatrix.Extensibility
組件: Microsoft.WebMatrix.Extensibility (在 Microsoft.WebMatrix.Extensibility.dll 中)
語法
'宣告
Protected Sub New ( _
label As String, _
command As ICommand, _
commandId As ICommandId, _
commandParameter As Object, _
smallImage As ImageSource, _
largeImage As ImageSource _
)
'用途
Dim label As String
Dim command As ICommand
Dim commandId As ICommandId
Dim commandParameter As Object
Dim smallImage As ImageSource
Dim largeImage As ImageSource
Dim instance As New RibbonButton(label, command, _
commandId, commandParameter, smallImage, _
largeImage)
protected RibbonButton(
string label,
ICommand command,
ICommandId commandId,
Object commandParameter,
ImageSource smallImage,
ImageSource largeImage
)
protected:
RibbonButton(
String^ label,
ICommand^ command,
ICommandId^ commandId,
Object^ commandParameter,
ImageSource^ smallImage,
ImageSource^ largeImage
)
new :
label:string *
command:ICommand *
commandId:ICommandId *
commandParameter:Object *
smallImage:ImageSource *
largeImage:ImageSource -> RibbonButton
protected function RibbonButton(
label : String,
command : ICommand,
commandId : ICommandId,
commandParameter : Object,
smallImage : ImageSource,
largeImage : ImageSource
)
參數
label
型別:System.String項目的標籤。
command
型別:System.Windows.Input.ICommand要在按下按鈕時叫用的命令。
commandId
型別:Microsoft.WebMatrix.Extensibility.ICommandId要在按下按鈕時叫用的 CommandId。
commandParameter
型別:System.Object命令或 CommandId 的命令參數。
smallImage
型別:System.Windows.Media.ImageSource按鈕的 16x16 影像。
largeImage
型別:System.Windows.Media.ImageSource按鈕的 32x32 影像。