| <table cellspacing="0" cellpadding="0" border="0" width="100%" height="100%" text-align="left"> |
| <tr> |
| <td> |
| <telerik:RadGrid ID="SearchResultsRadGrid" runat="server" |
| DataSourceID="SiteSearchResultsObjectDataSource" SkinID="RadGridHeaderSkin" |
| GridLines="Vertical" Style="margin: 0px 10px 0px 10px" OnSelectedIndexChanged="SearchResultsRadGrid_SelectedIndexChanged" |
| OnItemDataBound="SearchResultsRadGrid_ItemDataBound" |
| OnNeedDataSource="SearchResultsRadGrid_NeedDataSource" |
| AutoGenerateColumns="False" onprerender="SearchResultsRadGrid_PreRender" |
| Skin="Default"> |
| <MasterTableView DataKeyNames="ID" TableLayout = "Fixed" |
| DataSourceID="SiteSearchResultsObjectDataSource" Frame="Void"> |
| <NoRecordsTemplate> |
| No records to display ! |
| </NoRecordsTemplate> |
| <Columns> |
| <telerik:GridTemplateColumn HeaderText="Status" UniqueName="TemplateColumn"> |
| <ItemTemplate> |
| <asp:Label ID="StatusImageLabel" runat="server"></asp:Label> |
| </ItemTemplate> |
| <HeaderStyle Font-Names="Trebuchet MS" Font-Size="14px" ForeColor="#3496b4" Width="60px" /> |
| </telerik:GridTemplateColumn> |
| <telerik:GridBoundColumn DataField="Name" HeaderText="Site Name" SortExpression="Name" |
| UniqueName="Name"> |
| <HeaderStyle Font-Names="Trebuchet MS" Font-Size="14px" ForeColor="#3496b4" Width="40%" /> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="City" HeaderText="City" SortExpression="City" |
| UniqueName="City"> |
| <HeaderStyle Font-Names="Trebuchet MS" Font-Size="14px" ForeColor="#3496b4" Width="15%" /> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="StateName" HeaderText="State" SortExpression="StateName" |
| UniqueName="StateName" ReadOnly="True"> |
| <HeaderStyle Font-Names="Trebuchet MS" Font-Size="14px" ForeColor="#3496b4" Width="15%" /> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="CountryName" HeaderText="Country" SortExpression="CountryName" |
| UniqueName="CountryName" ReadOnly="True"> |
| <HeaderStyle Font-Names="Trebuchet MS" Font-Size="14px" ForeColor="#3496b4" Height="5px" Width="15%" /> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="Zipplus4" HeaderText="Zip" SortExpression="Zipplus4" |
| UniqueName="Zipplus4"> |
| <HeaderStyle Font-Names="Trebuchet MS" Font-Size="14px" ForeColor="#3496b4" Width="15%" /> |
| </telerik:GridBoundColumn> |
| <telerik:GridTemplateColumn HeaderText="Action" UniqueName="TemplateColumn1"> |
| <ItemTemplate> |
| <asp:ImageButton ID="EditImageButton" runat="server" CssClass="GridActionColumn" CommandArgument='<%# Eval("ID") %>' |
| ImageUrl="~/App_Themes/PANCAN_Theme/Images/edit.gif" ToolTip="Edit" OnClick="EditImageButton_Click" |
| CausesValidation="False" /> |
| <asp:LinkButton ID="PreviewLinkButton" runat="server" CssClass="GridActionColumn" CausesValidation="False" CommandName="Select" |
| EnableViewState="False" Visible="false">Preview</asp:LinkButton> |
| <asp:HiddenField ID="StatusHiddenField" runat="server" Value='<%# Eval("Active") %>' /> |
| </ItemTemplate> |
| <HeaderStyle Font-Names="Trebuchet MS" Font-Size="14px" ForeColor="#3496b4" Width="60px" /> |
| </telerik:GridTemplateColumn> |
| </Columns> |
| </MasterTableView> |
| </telerik:RadGrid> |
| <asp:ObjectDataSource ID="SiteSearchResultsObjectDataSource" runat="server" SelectMethod="SearchSite" |
| TypeName="ServiceLayer.SiteService"> |
| <SelectParameters> |
| <asp:ControlParameter ControlID="FindSiteHiddenField" Name="SearchString" PropertyName="Value" |
| Type="String" /> |
| <asp:ControlParameter ControlID="SiteStatusHiddenField" Name="Status" PropertyName="Value" |
| Type="String" /> |
| <asp:ControlParameter ControlID="ActionHiddenField" Name="Action" PropertyName="Value" |
| Type="String" /> |
| </SelectParameters> |
| </asp:ObjectDataSource> |
| </td> |
| </tr> |
Im using the TELERIK RAD GRID with DEAFULT SKIN(Q2 2009). I have folowing problem :-
Whenever I reorder my columns of the GRID the overall alignment of the page gets distubed. I have used the SKIN for the RED GRID(i.e. I have mentioned all the CLIENT SETTTING property for the GRID in SKIN file.) . I have placed my RAD GRID within in row of the Table with TABLE havong the follwing property :
Cellspacing = 0px
Cellpadding = 0px
Border = 0px
width = 100%
height = 100%
Now whenever , I reoder the columns of the RAD GRID & click on to the colums headers(try to sort), the RAD GRID gets STREACHED for its mean position, as a result of which the other controls on to the other <TD> of the Table gets distorted and overall structure of the webpage gets disturbed.
My providing you with the CODE that Iam using.
| This is the SKIN FILE for the RAD GRID. |
| --------------------------------------- |
| <telerik:RadGrid runat="server" Skinid="RadGridHeaderSkin"> |
| <ClientSettings EnableRowHoverStyle="true" EnablePostBackOnRowClick="true" AllowColumnsReorder="true" ReorderColumnsOnClient="true"> |
| <Resizing AllowRowResize="True" EnableRealTimeResize="false" ClipCellContentOnResize="false" ResizeGridOnColumnResize="true" AllowColumnResize="True"></Resizing> |
| <Scrolling AllowScroll="true" SaveScrollPosition="true" UseStaticHeaders="true" ScrollHeight="20px" /> |
| <Selecting AllowRowSelect="true" /> |
| </ClientSettings> |
| </telerik:RadGrid> |
Plase help to sort out this probelm.