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

Reset horizontal scroll bar on paging

1 Answer 70 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Ramakrishna
Top achievements
Rank 1
Ramakrishna asked on 08 Nov 2012, 03:50 PM
Hi,

I have Rad Grid with 13 columns so i have set 

If I change the page size everything is working fine. but if i move to the last column using horizontal scroll bar and by changing the page size the columns are getting mixed.

say my page size is 5..on page load the visible columns are C1, C2, C3, C4. if i move to last columns C10, C11, C12, C13 and changing the page size to 10, the first 5 rows display C10, C11, C12, C13 where as last 5 rows display C1, C2, C3, C4.

html of my grid

<telerik:RadGrid ID="grdLineManagement" runat="server" AllowFilteringByColumn="true" AllowCustomPaging = "true"
                    EnableEmbeddedSkins="false"  Skin="eMod"
                        AllowPaging="true" PageSize="10" Width="926" GridLines="None" AllowSorting="true" OnInit="grdLineManagement_Init">
                         
                        <ClientSettings AllowColumnsReorder="false" ReorderColumnsOnClient="true">
                            <DataBinding Location="../Services/ManageLinesService.asmx" SelectMethod="GetChassisPoolLines" />
                            <Resizing AllowResizeToFit="true" AllowColumnResize="true" />
                            <ClientEvents OnCommand="grdLineManagement_Command" OnRowDataBound="grdLineManagement_RowDataBound"/>                           
                            <Scrolling AllowScroll="true" ScrollHeight=""  UseStaticHeaders="true" FrozenColumnsCount="1" />                           
                        </ClientSettings>
                        <PagerStyle AlwaysVisible="True" PageButtonCount="5" />
                        <FilterMenu EnableImageSprites="False">
                        </FilterMenu>
                        <MasterTableView TableLayout="Fixed" CommandItemDisplay="Top"
                            HierarchyLoadMode="Client" ExpandCollapseColumn-Visible="false" >
                             <CommandItemTemplate>
                                <div class='fr tm10 bm10'>Export: <asp:ImageButton ID="btnExcel" runat="server"   ImageUrl="~/IMAGES/CONTROLS/ExcelExport.jpg"  onclick="btnExcel_Click"/>
                                 <asp:ImageButton ID="btnPdf" runat="server"  ImageUrl="~/IMAGES/CONTROLS/ExportPDF.jpg" onclick="btnPdf_Click"  /></div>
                                                               
                                </CommandItemTemplate>
                            <Columns>
                        <telerik:GridButtonColumn UniqueName="Edit" HeaderStyle-Width="50" Text="Edit" CommandName="Edit">
                        </telerik:GridButtonColumn>                         
                                <telerik:GridBoundColumn HeaderStyle-Width="180" FilterControlWidth="68px" DataField="ChassisPoolLineId"
                                            HeaderText="ChassisPoolLineId" UniqueName="ChassisPoolLineId"
                                            FilterListOptions="VaryByDataType" Visible="false">
                                </telerik:GridBoundColumn>                                                      
.
.
.
.
.
.
                                 
 <telerik:GridBoundColumn HeaderStyle-Width="125" HeaderStyle-Font-Bold="true" FilterControlWidth="85px" DataField="SalesTaxRate" DataType="System.Decimal"
                                    HeaderText="Sales Tax Rate" UniqueName="SalesTaxRate"  FilterListOptions="VaryByDataType" ItemStyle-HorizontalAlign="Right" HeaderStyle-HorizontalAlign="Right">
                                </telerik:GridBoundColumn>
                            </Columns>
                            <NestedViewTemplate>
                            </NestedViewTemplate>
                        <CommandItemSettings ShowAddNewRecordButton="false" ShowRefreshButton="false" ShowExportToExcelButton="true" />
                        </MasterTableView>
                                
                    </telerik:RadGrid>

Can anyone syggest me on this issue

1 Answer, 1 is accepted

Sort by
0
Pavlina
Telerik team
answered on 12 Nov 2012, 09:49 PM
Hello,

I noticed that you have custom paging enabled. Can you verify that you have implemented code logic which to extract merely a fixed number of records from the grid source and present them in the grid structure? If not you can try setting AllowCustomPaging property to false and see if it makes any difference.

Greetings,
Pavlina
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Grid
Asked by
Ramakrishna
Top achievements
Rank 1
Answers by
Pavlina
Telerik team
Share this question
or