Model view controller 如何使MVC4WebGrid序列号连续?
如何使不同页面的行号从第一页到最后一页连续 创建连续的行号Model view controller 如何使MVC4WebGrid序列号连续?,model-view-controller,webgrid,Model View Controller,Webgrid,如何使不同页面的行号从第一页到最后一页连续 创建连续的行号 I had faced such problem but solved already. you have to make the index of the row number as follows; declare a variable int rowVal=0; grid.Column(header: "Serial_No", format: item => rowVal = rowVal + 1 + (grid.Ro
I had faced such problem but solved already.
you have to make the index of the row number as follows;
declare a variable int rowVal=0;
grid.Column(header: "Serial_No", format: item => rowVal = rowVal + 1 + (grid.RowsPerPage * grid.PageIndex)),
-
*
> (grid.RowsPerPage * grid.PageIndex) ==> calculates the offset of the row index of the page number
-----------------------------------
-----------------------------------