Adding GroupBar Item to GroupBar in WPF Navigation Pane (GroupBar)
23 Oct 2019 / 1 minute to read
GroupBar Item is added to the GroupBar using XAML or C# code. The following code illustrates this.
<!-- Adding GroupBar -->
<syncfusion:GroupBar Height="200" Width="230" Name="groupBar">
<!-- Adding GroupBarItem -->
<syncfusion:GroupBarItem Name="groupBarItem" Header="GroupBarItem"/>
</syncfusion:GroupBar>
//Creating an instance of GroupBar
GroupBar groupBar = new GroupBar();
//Creating an instance of GroupBar
ItemGroupBarItem groupBarItem = new GroupBarItem();
//Setting header for GroupBar itemgroup
BarItem.Header = "GroupBarItem";
//Adding GroupBar item to GroupBar
groupBar.Items.Add(groupBarItem);
//Adding GroupBar to the window
this.Content = groupBar;
NOTE
To display the GroupBar Item, you must have a GroupBar in which you are going to add the GroupBar Item.
Was this page helpful?
Yes
No
Thank you for your feedback!
Thank you for your feedback and comments. We will rectify this as soon as possible!
An unknown error has occurred. Please try again.
Help us improve this page