Hi Stephly,
Apologize for the delay.
We have analysed your query. You can add a customized Ribbon
Tabs in SpreadsheetRibbon like the below snippet
CODE SNIPPET:
void SpRibbon_Loaded(object sender, RoutedEventArgs e)
{
var ribbon = (this.SpRibbon as FrameworkElement).FindElementOfType<Ribbon>();
if (ribbon != null)
{
RibbonTab rb = new RibbonTab();
rb.Caption = "Custom";
RibbonButton
Button1 = new RibbonButton();
Button1.Label = "Hide
1st Row";
Button1.Click += new System.Windows.RoutedEventHandler(Button1_Click);
CustomRibbonBar = new RibbonBar();
CustomRibbonBar.Header = "CustomOptions";
CustomRibbonBar.Items.Add(Button1);
CustomRibbonBar.IsLauncherButtonVisible = false;
rb.Items.Add(CustomRibbonBar);
ribbon.Items.Add(rb);
}
}
|
We have also prepared a sample based on your requirement. Please
see the below link for your reference
Please let us know if you have any queries.
Thanks
Kanimozhi B
Attachment:
CustomRibbonTab_6c9c025b.zip