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

Pager item moves from bottom to top on postback

4 Answers 140 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Margo Noreen
Top achievements
Rank 1
Veteran
Margo Noreen asked on 09 Sep 2010, 09:26 PM
I am seeing some strange behavior from the RadGrid I have on my page (asp.net 3.5/VS 2008 all SP1).  On the page load, the grid binds correctly to my datasource and displays just fine, including a nice "Items x of y" at the bottom of the grid.  The problem is I also have a button on the page the user can click that displays a previously hidden panel, all simple stuff (button does a postback, the onclick handler is wired up, and the visible property of the panel is toggled... nothing touches the grid in code at this point).  But, when that button gets clicked, all of sudden the Pager item/row is now displayed at the TOP of my grid, above the column headers!

       <telerik:RadGrid ID="RadGrid1" runat="server" SkinID="RadGrid" AllowPaging="True" AllowSorting="true"
OnEditCommand="Grid_EditCommand" OnDeleteCommand="Grid_DeleteCommand" OnUpdateCommand="Grid_UpdateCommand"
DataSourceID="myDataSourceGoesHere" PageSize="20" GridLines="None">
  
<PagerStyle AlwaysVisible="True" Mode="NumericPages" ShowPagerText="true" PagerTextFormat="{4}Items {2} to {3} of {5}" />
  
<MasterTableView DataKeyNames="EFileID" ShowFooter="False" EditMode="EditForms" DataSourceID="myDataSourceGoesHere">
  
<NoRecordsTemplate>
                    No files.
</NoRecordsTemplate>
<Columns>
.
.
.

4 Answers, 1 is accepted

Sort by
0
Margo Noreen
Top achievements
Rank 1
Veteran
answered on 09 Sep 2010, 09:49 PM

Actually, let me clarify.. 

My RadGrid has the following PagerStyle markup set on it:

<PagerStyle AlwaysVisible="True" Mode="NumericPages" ShowPagerText="true" PagerTextFormat="{4}Items {2} to {3} of {5}" Position="Bottom" />

+ On the first page load, no pager text is displayed whatsoever.

+ when I click the button in an edit column to edit a row (and either save or cancel that edit, doesn't matter), the pager text still is not displayed

+ it's only when I click a button on the page which resides outside of the RadGrid that the pager text is finally displayed, but now it's displayed at the top of the grid, above the column headers (which is not where I want it at all).

I'm thinking there must be some markup that I'm messing up or missing that is causing this very odd behavior.  Can you please advise?

Thanks in advance.
0
Pavel
Telerik team
answered on 10 Sep 2010, 08:07 AM
Hello Margo,

There was a problem withe the Q1 2010.1 309 release similar to the one you describe. If you are using that version of the controls, please update to a newer one and let us know if that helps.

All the best,
Pavel
the Telerik team
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 Public Issue Tracking system and vote to affect the priority of the items
0
Margo Noreen
Top achievements
Rank 1
Veteran
answered on 10 Sep 2010, 10:07 PM
I have downloaded the latest SP, and the problem with the pager item jumping around seems to be solved, but... I'm still getting strange results.  I have the following coded:

<PagerStyle Mode="NumericPages" PagerTextFormat="{4}Items {2} to {3} of {5}"
               Position="Bottom" ShowPagerText="True" PageSizeLabelText="" AlwaysVisible="False" />

But what is displayed when I view the page is the pager arrow icons for first, prev, then page numbers, then next, then last... then the Page size: with a dropdrownlist showing the page size I have set.  And the pager text is completely off:

Something like

<<  <  1 2 3 4 5 > >>              Page Size:  15 (dropdown)                        21 items in 2 pages


I have exited Visual Studio and shutdown the web server (thinking I needed to truly FORCE a refresh in case something was getting cached).  I copied the DLL and the update page to our dev web server that is actually running IIS.  And I get the same results displayed that clearly do not seem to reflect the markup.
0
Pavel
Telerik team
answered on 13 Sep 2010, 08:07 AM
Hello Margo,

I cannot reproduce this problem. You can find attached to this message the test page I used as well as screenshot illustrating the rendering of the pager. Let me know what else is needed to replicate the issue or if I am missing something.

Greetings,
Pavel
the Telerik team
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 Public Issue Tracking system and vote to affect the priority of the items
Tags
Grid
Asked by
Margo Noreen
Top achievements
Rank 1
Veteran
Answers by
Margo Noreen
Top achievements
Rank 1
Veteran
Pavel
Telerik team
Share this question
or