<asp:ListView runat="server" ID="listview2" EnableModelValidation="True"
>
<LayoutTemplate>
<table cellpadding="2" runat="server" id="tblEmployees"
style="width:460px">
<tr runat="server" id="itemPlaceholder">
</tr>
</table>
<asp:DataPager runat="server" ID="DataPager" PageSize="3">
<Fields>
<asp:NumericPagerField
ButtonCount="5"
PreviousPageText="<--"
NextPageText="-->" />
</Fields>
</asp:DataPager>
</LayoutTemplate>
<ItemTemplate>
<tr id="Tr1" runat="server">
<td valign="top" colspan="2" align="center"
>
<asp:Label ID="FirstNameLabel" runat="server"
Text='<%#Eval("fuliid") %>' />
<asp:Label ID="LastNameLabel" runat="server"
Text='<%#Eval("fuli1") %>' />
</td>
</tr>
<tr id="Tr2" style="height:72px" runat="server">
<td valign="top" >
<asp:Label ID="JobTitleLabel" runat="server"
Text='<%#Eval("fuli2") %>' />
<br />
<asp:Label ID="PhoneLabel" runat="server"
Text='<%#Eval("fuli1") %>' />
</td>
</tr>
</ItemTemplate>
</asp:ListView>
*********************************************************************************
string sql = "select * from laiyuan ";
SqlConnection sqlconn = new SqlConnection(ConfigurationManager.AppSettings["Connection"]);
SqlDataAdapter sqldr = new SqlDataAdapter(sql, sqlconn);
DataSet ds = new DataSet("laiyuan");
sqldr.Fill(ds);
listview2.DataSource = ds;
listview2.DataBind();