toggleButton

In the object model this is RibbonToggleButton.
A toggleButton is a clickable item that toggles between being pressed and not pressed.
There is a Click event that is raised when the user clicks the togglebutton


<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui"> 
  <ribbon startFromScratch="true">
    <tabs>
      <tab id="CustomTab" label="My Tab">
        <group id="Group1" label="Group 1">
          <toggleButton id="MyToggleButton1"
                        label="Toggle with text"
                        size="normal"
                        onAction="ToggleButton1_OnAction"/>
          <toggleButton id="MyToggleButton2"
                        label="Toggle with image and text"
                        imageMso="LeaveReader"
                        size="normal"
                        onAction="ToggleButton1_OnAction"/>
          <separator id="Separator1"/>
          <toggleButton id="MyToggleButton3"
                        label="Toggle Large"
                        imageMso="HappyFace"
                        size="large"
                        onAction="ToggleButton2_OnAction"/>
        </group>
      </tab>
    </tabs>
  </ribbon>
</customUI>

Attributes (Properties)

description(Description)
enabled"true" | "false"
id 
idMso(OfficeImageID)
idQ 
image 
imageMso 
insertAfterMso 
insertAfterQ 
insertBeforeMso 
insertBeforeQ 
keytip 
label(Label)
screentip(ScreenTip)
showImage"true" | "false"
showLabel(ShowLabel) "true" | "false"
size(ControlSize)
supertip(SuperTip)
tag(Tag)
visible"true" | "false"
 (Checked)

Callbacks

onActionToggleButton_OnAction
getDescriptionToggleButton_OnGetDescription
getEnabledToggleButton_OnGetEnabled
getImageToggleButton_OnGetImage
getImageMsoToggleButton_On
getKeytipToggleButton_OnGetKeytip
getLabelToggleButton_OnGetLabel
getPressedToggleButton_OnGetPressed
getScreentipToggleButton_OnGetScreentip
getShowImageToggleButton_OnGetShowImage
getShowLabelToggleButton_OnGetShowLabel
getSizeToggleButton_On
getSupertipToggleButton_OnGetSupertip
getVisibleToggleButton_OnGetVisible

Public Sub ToggleButton_OnAction( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef isPressed As Boolean)

End Sub

' C# Equivalent
public void ToggleButton_OnAction(

Office.IRibbonControl control,

   bool pressed) 
{
}

Public Sub ToggleButton_OnGetDescription( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetEnabled( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetImage( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetKeytip( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetLabel( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetPressed( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetScreentip( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetShowImage( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetShowLabel( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetSupertip( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub

Public Sub ToggleButton_OnGetVisible( _ 
   ByRef control As Microsoft.Office.Core.IRibbonControl, _
   ByRef ReturnedValue As Variant)

End Sub


© 2019 Better Solutions Limited. All Rights Reserved. © 2019 Better Solutions Limited TopPrevNext