Saya merasa sangat merepotkan sekarang. Apakah berikut ini cukup sederhana?
Salinan kode adalah sebagai berikut:
<%
Dimi, J, Icols
i = 0 '// Tentukan i untuk loop
icols = 3 '// Berapa banyak kolom yang ada dalam satu baris (bilangan bulat positif)
Response.write ("<tableWidth =" "100%" "border =" "1" "cellspacing =" "2" "cellpadding =" "0" "> <tr>" & vbnewline) '// header tabel output dan tr pertama
Dowhilenotors.eof '// Mulai Rekam Output Set dengan FORORS.RecordCountNext, juga ok
Ifi> 0Andimodicols = 0ThenResponse.write ("</tr> <tr>" & vbnewline) '// Jika jumlah kolom sama dengan ICOLS Line Break ICOLS
i = i+1
Response.write ("<tdwidth =" "" & formatPercent (1/icols, 0) & "" ""> output "& i &" Record </td> "& vbnewline)
ors.movenext
Loop '// akhiri set catatan output
ors.close
Forj = 1toicols-1 '// Mulailah menebus catatan kosong, dan hingga 1 icols-1
Ifimodicols = 0thenexitfor '// Jumlah kolom cukup icols tidak akan lagi output
i = i+1
Response.write ("<tdwidth =" "" "& formatcent (1/icols, 0) &" "" "> isi" & j & "Record </td>" & vbnewline)
Berikutnya
Response.write ("</tr> </able>" & vbnewline) '// output tabel tail
%>