By the way, the code syntax provided uses the VS2008 IDE but the code can be compiled under 2.0 or 3.x
>> new LinkButton { ID = "SelectAllButton", Text = "All", CausesValidation = false };
Main Topics
Browse All TopicsHi,
I have a GridView. And i set its properties like:
AllowPaging="true"
PageSize="4"
Now in the footer i have the paging like this, if i have more than 4 records:
1 2 3 4 5 6 7 8 9
I want to have ALL option with 1 2 3 4 5 6 7 8 9 means:
1 2 3 4 5 6 7 8 9 ALL
When user clicks on ALL it should display ALL the records.
Can you please provide me the code to achieve this ?
Thanks
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Business Accounts
Answer for Membership
by: b1xml2Posted on 2008-08-03 at 07:40:15ID: 22147669
<asp:GridView ID="UsersGridView" runat="server" AutoGenerateColumns="False
DataSourceID="UsersObjectD
BackColor="White" BorderColor="#E7E7FF" BorderStyle="None" BorderWidth="1px"
CellPadding="3" GridLines="Horizontal" onrowcreated="GridView_Row
<FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" />
<RowStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" />
<Columns>
<asp:BoundField DataField="FirstName" HeaderText="First Name" />
<asp:BoundField DataField="LastName" HeaderText="Last Name" />
<asp:BoundField DataField="Title" HeaderText="Title" />
</Columns>
<PagerStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" HorizontalAlign="Right" />
<SelectedRowStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" />
<HeaderStyle BackColor="#4A3C8C" Font-Bold="True" ForeColor="#F7F7F7" />
<AlternatingRowStyle BackColor="#F7F7F7" />
</asp:GridView>
- The PagerTable is the first control of the first cell of the PagerRow.
- This object is marked as internal and is a subclass of the Table class.
- Hence, we cast the control to the Table object and access the links on the first Row of the table.
Please note that in event that the button "ALL" is clicked, the paging will be shut off and as such, you should expect to see the entire data without any pager.Select allOpen in new window