日期:2014-05-17  浏览次数:20485 次

求教老问题,gridview分页问题
我个人做的一个girdview手动分页显示是这样的

但是要求是做一个全功能的分页,最好是


觉得添加12345之类的我不会,因为gridview自动的分页就是这样。特来求教。最好有代码。我是个新手做的比较简单,最好有代码。谢谢了~~
gridview分页

------解决方案--------------------
http://www.cnblogs.com/studyzy/archive/2008/07/30/1256877.html
------解决方案--------------------
 
具体的就不写了就写下分页
<PagerTemplate>
                            <div>
                                <asp:LinkButton ID="cmdFirstPage" runat="server" CommandName="Page" CommandArgument="First"
                                    Enabled="<%# ((GridView)Container.Parent.Parent).PageIndex!=0 %>">首页</asp:LinkButton>
                                <asp:LinkButton ID="cmdPreview" runat="server" CommandArgument="Prev" CommandName="Page"
                                    Enabled="<%# ((GridView)Container.Parent.Parent).PageIndex!=0 %>">前页</asp:LinkButton>
                                <asp:LinkButton ID="cmdNext" runat="server" CommandName="Page" CommandArgument="Next"
                                    Enabled="<%# ((GridView)Container.Parent.Parent).PageIndex!=((GridView)Container.Parent.Parent).PageCount-1 %>">后页</asp:LinkButton>
                                <asp:LinkButton ID="cmdLastPage" runat="server" CommandArgument="Last" CommandName="Page"
                                    Enabled="<%# ((GridView)Container.Parent.Parent).PageIndex!=((GridView)Container.Parent.Parent).PageCount-1 %>">尾页</asp:LinkButton>
                                第<asp:Label ID="lblcurPage" runat="server" Text='<%# ((GridView)Container.Parent.Parent).PageIndex+1      %>'></asp:Label>页/共<asp:Label
              &