Dear Sir/Madam,
Here I am adding Ribbonbar, RibbonbarTab, RibbonbarGroup and RibbonbarButtons from codebehind. Now in output window I am getting somehow mess up situation for buttons in groups. Please assist me how to resize Ribbonbar Groups? Also please find attached image for better understanding.
Here Is my Code to add Ribbonbar.
Here I am adding Ribbonbar, RibbonbarTab, RibbonbarGroup and RibbonbarButtons from codebehind. Now in output window I am getting somehow mess up situation for buttons in groups. Please assist me how to resize Ribbonbar Groups? Also please find attached image for better understanding.
Here Is my Code to add Ribbonbar.
RibbonBarTab objRibbonBarTab = new RibbonBarTab();RibbonBarGroup objRibbonBarGroup = new RibbonBarGroup();RibbonBarButton objRibbonBarButton = new RibbonBarButton();foreach (AM am in objList){ //Prepare tabs and add it to ribbon bar objRibbonBarTab = new RibbonBarTab(); objRibbonBarTab.Text = am.DisplayName; objRibbonBarTab.ID = am.Action_Menu_ID.ToString(); objRibbonBarTab.ToolTip = am.Description; objRadRibbonBar.Tabs.Add(objRibbonBarTab); //Adding Tab to RibbonBar //Add Groups to above tab if (ChildList.Count > 0) { foreach (Child objSingle in ChildList) { objRibbonBarGroup = new RibbonBarGroup(); objRibbonBarGroup.EnableLauncher = true; objRibbonBarGroup.Text = objSingle.DisplayName; objRibbonBarGroup.ID = objSingle.ActionMenuChildID.ToString(); objRibbonBarGroup.ToolTip = objSingle.Description; objRibbonBarTab.Groups.Add(objRibbonBarGroup); //Adding Groups to Tabs //Add RaButtons to above Groups if (objRadGroupsList.Count > 0) { foreach(Child objMap in objRadGroupsList) { objRibbonBarButton = new RibbonBarButton(); objRibbonBarButton.Text = objMap.DisplayName; objRibbonBarButton.ID = objMap.ActionMenuChildID.ToString(); objRibbonBarButton.ToolTip = objMap.Description; objRibbonBarButton.Value = objMap.Name; switch(objMap.Size) { case "Large": objRibbonBarButton.Size = RibbonBarItemSize.Large; break; case "Medium": objRibbonBarButton.Size = RibbonBarItemSize.Medium; break; case "Small": objRibbonBarButton.Size = RibbonBarItemSize.Small; break; } RibbonBarItem objRibbonBarItem = objRibbonBarButton; objRibbonBarGroup.Items.Add(objRibbonBarItem); } } } }}