This is a migrated thread and some comments may be shown as answers.

[Solved] Grid column resizing with a master page.

2 Answers 115 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Dan Lewis
Top achievements
Rank 1
Dan Lewis asked on 02 Jun 2009, 04:35 PM
Hello,
 I'm having a problem with the clientside column resizing on grids that are contained in an ASP:ContentPlaceholder for a master page. 
When using the grids on a stand alone page (like in a RadWindow popup that does not inherit from the master page), I've not had an issue with resizing columns. 
The column reorder, item sort and filtering are fine.  But when hovering the mouse over the column dividers, it does not change pointers to the re-size, and you can't drag any of of cell divider lines (column or row) to re-size. 

The site is being tested on IE7 with .NET 3.5 installed. 
Below is the markup for one of the grids I've been having an issue with:
It's contained within an update panel and an ASP formview that are the main elements in the content placeholder.
The script manager tag is on the master page.



<telerik:RadGrid  
                            ID="rgvRepository"  
                            runat="server"  
                            AllowPaging="True"  
                            OnNeedDataSource="rgvRepositoryAccounts_NeedDataSource" 
                            OnItemDataBound="rgv_OnItemDataBound" 
                            GridLines="None" 
                            Skin="Office2007"  
                            Width="700px"  
                            AllowCustomPaging="False"  
                            PageSize="5"   
                            AllowSorting="True"  
                            ForeColor="Black"  
                            AutoGenerateColumns="False"
                            <MasterTableView TableLayout="Auto"
                                <RowIndicatorColumn> 
                                    <HeaderStyle Width="20px" /> 
                                </RowIndicatorColumn> 
                                 
                                <ExpandCollapseColumn> 
                                    <HeaderStyle Width="20px" /> 
                                </ExpandCollapseColumn> 
                                
                                <HeaderStyle Wrap="true" HorizontalAlign="Center"/> 
                 
                        <Columns> 
                        <telerik:GridBoundColumn DataField="C06NAME" EmptyDataText="&amp;nbsp;"  
                            HeaderText="Name" MaxLength="35" UniqueName="C06NAME" Resizable="true"
                        </telerik:GridBoundColumn> 
                        <telerik:GridBoundColumn DataField="C06ACCT" EmptyDataText="&amp;nbsp;"  
                            HeaderText="Account" MaxLength="30" UniqueName="C06ACCT" Resizable="true"
                        </telerik:GridBoundColumn> 
                        <!-- More gridbound coloumns with the same options removed. --> 
                    </Columns> 
                </MasterTableView> 
                <ClientSettings  
                                    AllowColumnHide="false"  
                                    AllowColumnsReorder="true"  
                                    ReorderColumnsOnClient="true" 
                                    ColumnsReorderMethod="Reorder"
                                <Selecting AllowRowSelect="true" /> 
                                 
                    <ClientEvents OnRowSelected="SelectAccountRow"  
                                  OnRowContextMenu="RowClicked" /> 
                    <Resizing AllowRowResize="True" EnableRealTimeResize="True" ResizeGridOnColumnResize="True" 
                                AllowColumnResize="True"></Resizing> 
                    <Scrolling AllowScroll="true" /> 
                </ClientSettings> 
                <FilterMenu EnableTheming="True"
                    <CollapseAnimation Duration="200" Type="OutQuint" /> 
                </FilterMenu> 
             
            </telerik:RadGrid> 
 

Here is some of the master page (I've omitted some static items, images and the like for brevity).  All the grids on child pages would be within the contentplaceholder1 control.
<form id="mmaster" defaultbutton="btnOK"  runat="server"
     
    <asp:ScriptManager ID="ScriptManager1" runat="server" /> 
           
          <div class="PageTitle"
          <asp:Label  CssClass="TextPadl" Font-Bold="true" Height="25px" ID="lblPageTitle" runat="server" Text=""></asp:Label>  
           <br /> 
          <asp:Label CssClass="TextPadl" runat="server" ForeColor="red" ID="lblError"  ></asp:Label> 
      </div> 
       
      <div  id="sidemenudiv" runat="server" class="mLeftMenu"
            
           <asp:Label CssClass="mLeftMenuL" ID="lblSystem" runat="server">  
            
           </asp:Label> 
            
           <br /> 
           <br /> 
           <br /> 
 
          <asp:ContentPlaceHolder  ID="ContentPlaceHolder2" runat="server" > 
        
            </asp:ContentPlaceHolder> 
          
          <UserControl:TreeViewControl ID="TreeViewControl" runat="server" /> 
           
           
            
     </div> 
      
      
        <div class="Buttons" > 
            <asp:Button ID="btnOK" runat="server" CssClass="Button" /> 
            <asp:Button ID="btnCancel" runat="server" CssClass="Button" CausesValidation="false" /> 
            <asp:Button ID="btnApply" runat="server" CssClass="Button" /> 
            <asp:Button ID="btnClear" runat="server" CssClass="Button" /> 
            <br/> <br/> 
        </div> 
     
     
     <div id="msDiv" runat="server" class="ContentHolder"
         <div id="DebtorRow" runat="server" style="position:relative; left:30px; top:10px; width:300px;"
             <asp:Label ID="lblDCode"   Width="70px" Font-Bold="true" ForeColor="blue"  runat="server" ></asp:Label> 
             <asp:Label ID="lblDCodeVal"  runat="server" ></asp:Label> 
         </div> 
        <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server"
        
        </asp:ContentPlaceHolder> 
    </div> 

Hopefully I'm just missing an option, or need to configure something something on the master page, but I'm having trouble finding what that might be.
Thanks for any suggestions as to what I'm doing wrong.
 

2 Answers, 1 is accepted

Sort by
0
Sebastian
Telerik team
answered on 05 Jun 2009, 10:32 AM
Hello Dan,

Can you please check whether setting margin: 0px; padding: 0px; through the body tag of your master page addresses this discrepancy? It is possible that some custom css style settings on the master page conflict with the grid column/row resizers appearance and dislocate them.

If this does not help, I will appreciate if you can provide a live url where the abnormality can be observed. Thus I will do my best to help you eliminate it. You may also use IE developer toolbar or FireBug to check the rendered html of the page and designate the cause of the odd behavior.

Kind regards,
Sebastian
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Dan Lewis
Top achievements
Rank 1
answered on 05 Jun 2009, 12:46 PM
The body style resolved it, many thanks Sebastian.
Tags
Grid
Asked by
Dan Lewis
Top achievements
Rank 1
Answers by
Sebastian
Telerik team
Dan Lewis
Top achievements
Rank 1
Share this question
or