DataList用法
//DataList套用table要放在外才行
<table>
<asp:DataList id="DataList1" style="Z-INDEX: 101; LEFT: 32px; POSITION: absolute; TOP: 144px"
runat="server" Height="176px">
<headertemplate>
<tr><td>A1</td><td>A2</td><td>A3</td><td>A4</td><td>A5</td><td>A6</td><td>A7</td><td>A8</td><td>修改</td><td>删除</td></tr>
</headertemplate>
<itemtemplate>
<tr>
<td><%# DataBinder.(Container.DataItem,"A1") %></td>
<td><%# DataBinder.(Container.DataItem,"A2") %></td>
<td><%# DataBinder.(Container.DataItem,"A3") %></td>
<td><%# DataBinder.(Container.DataItem,"A4") %></td>
<td><%# DataBinder.(Container.DataItem,"A5") %></td>
<td><%# DataBinder.(Container.DataItem,"A6") %></td>
<td><%# DataBinder.(Container.DataItem,"A7") %></td>
<td><%# DataBinder.(Container.DataItem,"A8") %></td>
<td><a href='UpdateTable.aspx?id=<%# DataBinder.(Container.DataItem,"id") %>' target="_blank"> 修改</a></td>
<td><a href='WebForm1.aspx?id=<%# DataBinder.(Container.DataItem,"id") %>'> 删除</a></td>
</tr></itemtemplate>
</asp:DataList>
</table>
<table>
DataGrid分页的例子
<%@ Page language="c#" Codebehind="ArticleList.aspx.cs" AutoEventWireup="false" Inherits="MyCms.Manage.ArticleList" %>
<%@ Register TagPrefix="uc1" TagName="LeftMenu" Src="LeftMenu.ascx" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
<HEAD>
<title>ArticleList</title>
<meta name="GENERATOR" Content="Microsoft Visual Studio .NET 7.1">
<meta name="CODE_LANGUAGE" Content="C#">
<meta name="vs_defaultClientScript" content="JavaScript">
<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5">
</HEAD>
<body bgColor="#e6e7e8" leftMargin="0" topMargin="0" marginheight="0" marginwidth="0">
<form id="MainForm" method="post" runat="server">
<input id="txtID" type="hidden" name="txtID" runat="server">
<table height="100%" cellSpacing="0" cellPadding="0" width="87%" align="center" bgColor="#ffffff" border="0">
<tr>
<td style="WIDTH: 913px; HEIGHT: 74px" colSpan="2">
<table height="6%" cellSpacing="0" cellPadding="0" border="0">
<tr>
<td><IMG src="/MyCms/images/top_1.jpg" border="0"></td>
<td><IMG src="/MyCms/images/top_2.jpg" border="0"></td>
</tr>
</table>
</td>
</tr>
<%@ Register TagPrefix="uc1" TagName="LeftMenu" Src="LeftMenu.ascx" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>