suppose DataGrid named dgCustomize, insert the following code to the first column. <asp:TemplateColumn HeaderText="No."> <ItemStyle HorizontalAlign="Center"></ItemStyle> <ItemTemplate> <asp:Label runat="server" Text='<%# dgCustomize.CurrentPageIndex*dgCustomize.PageSize+dgCustomize.Items.Count+1 %>'> </asp:Label> </ItemTemplate></asp:TemplateColumn> 相关文章: 2021-09-24 2021-12-04 2021-06-21 2022-02-25 2021-12-27