I am using the following Way to do. Steps are following:
1. I create a new Column Group and Added a label and stack panel with 4 buttons and place all of them in Grid like following in the code and finally assigned that grid into Header Template of RadGridView property.
<DataTemplate
xmlns=""http://schemas.microsoft.com/winfx/2006/xaml/presentation""
xmlns:x=""http://schemas.microsoft.com/winfx/2006/xaml""
xmlns:Tele=""http://schemas.telerik.com/2008/xaml/presentation""
xmlns:Event=""clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity""
xmlns:cmd=""clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.WPF4"" >
<Grid HorizontalAlignment=""Stretch"" VerticalAlignment=""Stretch"" Background=""#EAF3FC"" Name=""grdcolumnHeader2"" >
<Grid.RowDefinitions>
<RowDefinition Height=""23""></RowDefinition>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width=""*""></ColumnDefinition>
<ColumnDefinition Width=""Auto""></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Name=""lblMonthName"
+ groupIndex.ToString() + @""" Grid.Row=""0"" Grid.Column=""0"" HorizontalAlignment=""Stretch"" HorizontalContentAlignment=""Center"" Padding=""0"" Margin=""0,2,0,0"" FontWeight=""DemiBold""
Content="""
+ monthContent + @"""></Label>
</Grid>
</DataTemplate>";
2. After creating new column Group, adding it into RadGridView like following and assigned it name like "month1"
RadGridView1.ColumnGroups.add(newColumnGroup);
3. the created dynamic columns based on no of days in a months and assigned column group name "month1"
newcolumn.ColumnGroupName="month1";
RadGridView1.Columns.Add(newcolumn);
This functionality works fine in version 2011 Q3 and 2012 Q2 releases.
But my issues is when I use 2012 Q2 version of telerik controls the Label controls and Panel with 4 buttons in the Colum Group Header does not cover all the columns and leave black color space at right side columns. screen shot has been attached with this thread. Please have a look and provide solution.
Note: If you do not understand anything please let me know. I will explain further.
Please help me to resove this issue. I am running out of solution.
Thanks
Laxman