HTML table vs ASP.Net table

aliweb

Active member
Joined
Sep 14, 2005
Messages
40
Programming Experience
3-5
Hello,

If we want to display records in ASP then we simply loop through them and display them as follows

VB.NET:
<%While not rs.EOF%>
       <td><%=rs("Record1")%></td>
<%
rs.MoveNext
Wend
%>

Now what is the best way to do this in ASP.Net? Shall I create an ASP.Net table control?
Basically I want to display records as shown in the screenshot. What is the best way to do that in ASP.Net?
 

Attachments

  • screenshot.JPG
    screenshot.JPG
    65.3 KB · Views: 149
I just noticed I have posted it in wrong forum so please move it to ASP.Net General Discussion.
 
Yes it does support paging. Just, make sure that you've got 'Allow paging' checked using the property builder.
Make a procedure to bind the data and then just In the page_index_changed event handler add next lines:

VB.NET:
DataGrid1.CurrentPageIndex = e.NewPageIndex 
FillWithData() 'assuming that it's the name of your Sub

Regards ;)
 
Back
Top