Hi,
I have a situation where I have to keep grid header frozen. The trouble is horizontal scoll bar gets lost when when grouping is done by a column. Grid tries to squeeze all columns present in the template column.When I try to resize the columns in the templated column error is thrown.
I have got a radGrid and for some reason I have to have table inside a column. This particular column is giving me a headache.
Any help is deeply appreciated.
Please see the codesnippet below -
<telerik:RadGrid ID="gridRebate" runat="server" Skin="Office2007" BorderWidth="0px"
AutoGenerateColumns="false" AllowPaging="True" PageSize="500" AllowSorting="True">
<AlternatingItemStyle BackColor="AliceBlue" Font-Names="Verdana" Font-Size="8pt" />
<ItemStyle Font-Names="Verdana" Font-Size="8pt" />
<ClientSettings AllowColumnsReorder="True" ReorderColumnsOnClient="True">
<Resizing AllowRowResize="false" AllowColumnResize="True"></Resizing>
<Scrolling FrozenColumnsCount="8" SaveScrollPosition="true" UseStaticHeaders="true" AllowScroll="true"/>
</ClientSettings>
<MasterTableView TableLayout="auto">
<Columns>
<telerik:GridBoundColumn DataField="SupVendor" HeaderText="Supplier/Vendor"></telerik:GridBoundColumn>
<telerik:GridTemplateColumn UniqueName="RebateDeal" Groupable="false">
<HeaderTemplate>
<table id="Table1" cellspacing="1" cellpadding="1" width="300" border="0">
<tr>
<td colspan="2" align="center">Rebate Deal</td>
</tr>
<tr>
<td style="width:35%"></td>
<td style="width:35%"></td>
<td style="width:25%"></td>
<td style="width:10%"></td>
</tr>
</table>
</HeaderTemplate>
<ItemTemplate>
<table id="Table2" cellspacing="1" cellpadding="1" width="300" border="0" style="background-color:#ccff99">
<tr>
<td style="width:35%"><%#DataBinder.Eval(Container.DataItem, "RangeSpendFrom")%></td>
<td style="width:35%"><%# DataBinder.Eval(Container.DataItem, "RangeSpendTo") %></td>
<td style="width:25%"><%#DataBinder.Eval(Container.DataItem, "RebatePercent")%></td>
<td style="width:10%" id="RebateType"><%#DataBinder.Eval(Container.DataItem, "RebateType")%></td>
</td>
</tr>
</table>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridBoundColumn DataField="GRInvoice" HeaderText="GR/Inv." Display="false"></telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Spend" HeaderText="Spend" UniqueName="Spend"></telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="EstimatedRebate" HeaderText="Estimated Rebate" UniqueName="EstimatedRebate"></telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="GainedRebatePercent" HeaderText="%" UniqueName="GainedRebatePercent"></telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="SpendToNextLevel" HeaderText="Spend To Next Level" UniqueName="SpendToNextLevel"></telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="AdditionalRebate" HeaderText="Additional Rebate" UniqueName="AdditionalRebate"></telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="AdditionalRebatePercent" HeaderText="%" UniqueName="AdditionalRebatePercent"></telerik:GridBoundColumn>
</Columns>
<RowIndicatorColumn Visible="True">
<HeaderStyle Width="20px" />
</RowIndicatorColumn>
<ExpandCollapseColumn>
<HeaderStyle Width="20px" />
</ExpandCollapseColumn>
</MasterTableView>
<FilterMenu EnableTheming="True" Skin="Web20">
<CollapseAnimation Duration="200" Type="OutQuint" />
</FilterMenu>
<PagerStyle Mode="NextPrevAndNumeric" Position="TopAndBottom" />
</telerik:RadGrid>