Horizontal scroll not working when Frozen Columns Count is greater than one in Mozilla. Occurs only when there is no data in the grid.

4 posts, 0 answers
  1. Gopinath
    Gopinath avatar
    63 posts
    Member since:
    Sep 2011

    Posted 14 Oct 2015 Link to this post

    Hi,

     Horizontal scroll not working when Frozen Columns Count is greater than one in Mozilla. 

     I am facing this issue only when there is no data in the grid. 

     

     Example:  

    -------------

     <telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="False" AllowSorting="true" PageSize="10" AllowMultiRowEdit="true"
                    AllowAutomaticInserts="false" AllowAutomaticUpdates="false" Width="500px">
                    <ClientSettings>
                        <Resizing AllowColumnResize="true" ShowRowIndicatorColumn="true" />
                        <Selecting AllowRowSelect="true" />
                        <Scrolling AllowScroll="true" FrozenColumnsCount="3" SaveScrollPosition="true" UseStaticHeaders="true" />
                    </ClientSettings>
                    <MasterTableView AutoGenerateColumns="false" CommandItemDisplay="Top" EditMode="InPlace">
                        <Columns>
                            <telerik:GridBoundColumn DataField="Incident #" HeaderText="Incident #" UniqueName="Incident#">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Priority" HeaderText="Priority" UniqueName="Priority">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Open Time" HeaderText="Open Time" UniqueName="OpenTime">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Client Full Name" HeaderText="Client Full Name" UniqueName="ClientFullName">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Category" HeaderText="Category" UniqueName="Category">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Urgency" HeaderText="Urgency" UniqueName="Urgency">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Product Type" HeaderText="Product Type" UniqueName="ProductType">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Product Type" HeaderText="Product Type" UniqueName="ProductType">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Issue Type" HeaderText="Issue Type" UniqueName="IssueType">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Brief Description" HeaderText="Brief Description" UniqueName="BriefDescription">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Issue Type Detail" HeaderText="Issue Type Detail" UniqueName="IssueTypeDetail">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="RC" HeaderText="RC" UniqueName="RC">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Status" HeaderText="Status" UniqueName="Status">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Alert Stage" HeaderText="Alert Stage" UniqueName="AlertStage">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Last Action Type" HeaderText="Last Action Type" UniqueName="LastActionType">
                                <HeaderStyle Width="110px" />
                            </telerik:GridBoundColumn>
                        </Columns>
                        <EditFormSettings>
                            <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                            </EditColumn>
                        </EditFormSettings>
                    </MasterTableView>
                    <PagerStyle Mode="NextPrevAndNumeric" />
                </telerik:RadGrid> 

     To add the data for all the available columns, i have tried to scroll to right but columns are not getting displayed.

     While debugging the issue in the Mozilla i found "TypeError: h is undefined" is occuring as shown in the below.

     var h=b._owner.get_masterTableView()._getFirstDataRow();

    for(var m=b._owner.ClientSettings.Scrolling.FrozenColumnsCount;m<b._owner.get_masterTableView().get_columns().length;m++)
    {
      var c=b._owner.get_masterTableView().get_columns()[m];
      var y=false;
    if((window.netscape||$telerik.isSafari||$telerik.isIE8||($telerik.isOpera&&v>10.1))&&c.get_element().style.display=="none")
     {
       c.get_element().style.display="table-cell";
       y=true;
     }
    var u;
    if($telerik.isIE9Mode)
     {
       u=b._owner.get_masterTableView().ColGroup.Cols[m].style.width.replace("px","")*1;
     }
    else
     {
      if(!($telerik.isIE6||$telerik.isIE7)&&b._owner.get_masterTableView().ColGroup.Cols[m].style.width.indexOf("px")>-1)
       {
         if(typeof(h)=="undefined"&&h.cells[m].offsetWidth>0)
      {
        u=h.cells[m].offsetWidth;
           }
    else
     {
       u=parseInt(b._owner.get_masterTableView().ColGroup.Cols[m].style.width,10);
          }
       }
      else
       {
         u=(c.get_element().offsetWidth>0)?c.get_element().offsetWidth:(typeof(h)=="undefined"?0:h.cells[m].offsetWidth);
       }
     }
     s[s.length]={Index:m,Width:u,FrozenDisplay:true}; 
     if(typeof(c.FrozenDisplay)=="boolean")
      {
        s[s.length-1].FrozenDisplay=c.FrozenDisplay;
      }
     if((window.netscape||$telerik.isSafari||$telerik.isIE8||($telerik.isOpera&&v>10.1))&&y)
      {
       c.get_element().style.display="none";
       y=false;
      }
    }​

    Please let me know how to fix this.

     

  2. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 14 Oct 2015 Link to this post

    Hello,

    I tested the provided grid declaration, however, I was not able to observe any errors when there is no data in the grid. You can find attached my test page and see what is the difference in your case.

    Regards,
    Pavlina
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Gopinath
    Gopinath avatar
    63 posts
    Member since:
    Sep 2011

    Posted 20 Nov 2015 Link to this post

    We are using 2014.1.403.40 version so i still can see the issue. But the sample code has later version and i have tried with that version where i don't see the issue.

     Thank you. May be we need to update Telerik versions.

  5. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 23 Nov 2015 Link to this post

    Hello,

    I would recommend you upgrade to the latest version in order to take care of this issue. After the upgrade you will also be able to take advantage of the new controls and functionalities that are included in the latest releases.

    Regards,
    Pavlina
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top