Forum Moderators: open

Message Too Old, No Replies

Datalist Paging

Are the large drectory sites using cusomt Dalalist paging?

         

kevin_m

12:01 am on Jul 9, 2002 (gmt 0)

10+ Year Member



Hi I have been to a few .Net sites that have some great paging results in there directory. I am trying to build an art site which will be my first C# site in .net, but I have finding it quite difficult to produce numeric paging results with a DataList. Is there any resources out there that could help that I might have missed?

tomasz

12:52 am on Jul 9, 2002 (gmt 0)

10+ Year Member



IMHO, You have to use DataGrid to get paging. You can build data grid using custom template and get similar effect (unfortunately no horizontal repeat).

If you want to have horizontal repeat you would have to use store procedure to create on fly unique id so you can, get reference to page number and use DataList.

i.e

@PageNumber int

declare @IdStart int, @IdEnd int

select @IDStart=@PageNumber*5
select @IdEnd=@Pagenumber*10

select * from tblPictures where id>=@IdStart and id<=@IdEnd

If someone else has way to i would like to know to

kevin_m

1:34 pm on Jul 9, 2002 (gmt 0)

10+ Year Member



I have seen that example. I would like to use a Datagrid to keep it simple. The one thing I noticed with a Datagrid is that I can't have results that look like this with 2 rows or am I wrong?

Some title
Some short discription here.

tomasz

1:53 pm on Jul 9, 2002 (gmt 0)

10+ Year Member



Unfortunately with data grid you can have only one row of data, but you can have two data grids or more on one page with paging if you split your gallery to let say two or more different categories
It is not very efficient thought but may provide same or similar layout