bhavna_816 0 Junior Poster

Actually i have coded this whole thing in console and displaying the output as a table format in HTML.my output is something like this in HTML page:
Deleted Items
From: Subject: Received: Size: No.of Attachment(s):
bhavna final 1/12/2007 2:34:14 PM 4949 0
Inbox
From: Subject: Received: Size: No.of Attachment(s):
bhavna atmttest 1/22/2007 12:52:32 PM 6449 1
Now i want that if suppose i m having hundreds of records in my inbox then i have to allow paging like 10 or 20 records at a time.So is the datagrid is the right option for tht or i hv to go with the frames of the HTML?
The VB.NET code for displaying folderin an HTML table is:

'Looping all the subfolders
For j = 1 To 2
sfolder = oFol.Item(j)
s.WriteLine(sfolder.Name)
'Looping the Mailitems of the Subfolders with the sender's name, Subject,Recevied Time,Size of the mail
Dim i As Integer
For i = oItems.Count To 1 Step -1
s.WriteLine(oMail.Subject)
Next
Next
this "s" is the stream for displaying data in HTML page.from outer for loop I am displaying the folder names and from inner loop I am displaying the contents of that folders .
Now I want to do paging since in case of hundreds and thousands of msgs in my inbox.
So I think datagrid is the best option for tht
but I am getting how to populate the datagrid according to this and do paging in tht.And i hv no idea how to do it?