我要把表中的数据分行显示到table中,如下:
<script runat= "server ">
'Sub Page_Load(obj As object,e As eventargs)
Dim queryString As String = "select * from workflo2_bumen order by paixu "
Using connection As New OdbcConnection( "DSN=aa;uid=aa;pwd=** ")
Dim command As New OdbcCommand(queryString, connection)
connection.Open()
Dim reader As OdbcDataReader = command.ExecuteReader()
While reader.Read()
response.write(reader.getString(0)& " | "&reader.getString(1) & " <br> ")
response.Write( " <tr> ")
response.Write( " <td align= " "center " " nowrap style= " "border-bottom:1px dotted #8A9DC6;border-left:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 " "> <a href= " "huizhi.asp " "> <font color= " "#FFFFFF " "> reader.getString(1) </font> </a> </td> ")
response.Write( " <td align= " "right " " nowrap style= " "border-bottom:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 " "> </td> ")
response.Write( " <td align= " "right " " nowrap style= " "border-bottom:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 " "> </td> ")
response.Write( " <td align= " "right " " nowrap style= " "border-bottom:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 " "> </td> ")
response.Write( " <td align= " "right " " nowrap style= " "border-bottom:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 " "> </td> ")
response.Write( " <td align= " "right " " nowrap style= " "border-bottom:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 " "> </td> ")
response.Write( " <td align= " "right " " nowrap style= " "border-bottom:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 " "> </td> ")
response.Write( " <td align= " "right " " nowrap style= " "border-bottom:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 " "> </td> ")
response.Write( " </tr> ")
</script>
<tr>
<td align= "center " nowrap style= "border-bottom:1px dotted #8A9DC6;border-left:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 "> <a href= "huizhi.asp "> <font color= "#FFFFFF "> reader.getString(1) </font> </a> </td>
<td align= "right " nowrap style= "border-bottom:1px dotted #8A9DC6;border-right:1px dotted #8A9DC6 "> </td>