M
miladhatam
hi
how can i show every 10 records of my db in datalist in several page
i want to get it the paging property
i even wrote this code
AccessDataSource1.SelectCommand = "SELECT * FROM table1 where id
between " + (page - 1) * 10 + " and " + (page * 10 - 1) ;
but it works when my 'id' have a correct sequence of number
you know for example when you have 3 records with id 1,2,3 and when
you delete second record after that you have 2 records but your new
second record's id is still 3
and it make a mistake
what is your soloution for paging the datalist?
thanks
how can i show every 10 records of my db in datalist in several page
i want to get it the paging property
i even wrote this code
AccessDataSource1.SelectCommand = "SELECT * FROM table1 where id
between " + (page - 1) * 10 + " and " + (page * 10 - 1) ;
but it works when my 'id' have a correct sequence of number
you know for example when you have 3 records with id 1,2,3 and when
you delete second record after that you have 2 records but your new
second record's id is still 3
and it make a mistake
what is your soloution for paging the datalist?
thanks