According to Telerik's documentation for ASP.NET Ajax Controls 2010 Q1's RadGrid -
I have a table that has its TableLayout to fixed. I have 3 columns - all have fixed widths. Yet when I view the source, the rendered table has a width of 100% and the 3 columns have the same width (they are each a third of the grid). According to Telerik's documentation, that should not be the case.
What is going on?
Here is my exact markup of the RadGrid:
"The value of the TableLayout property is a string that specifies or receives one of the following GridTableLayout enumeration values:
Auto | Column width is set by the widest unbreakable content in the column cells. |
Fixed | Default. Table and column widths are set either by the sum of the widths on the GridTableView.Columns objects or, if these are not specified, by the width of the first row of cells. If no width is specified for the table, it renders by default with width=100%." |
I have a table that has its TableLayout to fixed. I have 3 columns - all have fixed widths. Yet when I view the source, the rendered table has a width of 100% and the 3 columns have the same width (they are each a third of the grid). According to Telerik's documentation, that should not be the case.
What is going on?
Here is my exact markup of the RadGrid:
<telerik:RadGrid ID="dgCourseCatalog" runat="server" AutoGenerateColumns="False" AllowSorting="true" BorderStyle="None"> |
<MasterTableView ShowHeadersWhenNoRecords="False" AllowNaturalSort="false" TableLayout="Fixed"> |
<SortExpressions> |
<telerik:GridSortExpression FieldName="LearningModuleName" SortOrder="Ascending" /> |
</SortExpressions> |
<NoRecordsTemplate> |
<div class="StatusUpdate Warning NoRecords"> |
No Learning Modules found with your search criteria. Please adjust your search. |
</div> |
</NoRecordsTemplate> |
<Columns> |
<telerik:GridTemplateColumn HeaderText="Type" UniqueName="LMType" ItemStyle-HorizontalAlign="Center" HeaderStyle-HorizontalAlign="Center"> |
<ItemStyle Width="30px" Wrap="true" /> |
<ItemTemplate> |
<img src='<%#ResolveUrl(Eval("LMTypeIconUrl"))%>' alt='<%#Eval("LMTypeDescription") %>' /> |
</ItemTemplate> |
</telerik:GridTemplateColumn> |
<telerik:GridHyperLinkColumn HeaderText="Name" DataTextField="LearningModuleName" SortExpression="LearningModuleName" DataNavigateUrlFormatString="~/learning/learningmodulehome.aspx?LMID={0}" |
DataNavigateUrlFields="LearningModuleID" UniqueName="LearningModuleName" ItemStyle-Width="250px" ItemStyle-Wrap="true" /> |
<telerik:GridBoundColumn HeaderText="Description" DataField="LearningModuleDescription" UniqueName="LearningModuleDescription" |
SortExpression="LearningModuleDescription" ItemStyle-Width="250px" ItemStyle-Wrap="true" /> |
</Columns> |
</MasterTableView> |
</telerik:RadGrid> |