現在、コードビハインドでデータをループさせるソリューションを探していますか?
実際には、タイトルと内容を含むデータベースからクエリを実行するお知らせリストです。
cmdDa = New SqlDataAdapter("SELECT * FROM announcement ORDER BY announcement_PostDT DESC", conn)
ds = New DataSet()
cmdDa.Fill(ds, "announcement")
Dim total_rows_count As Integer = ds.Tables("announcement").Rows.Count - 1
For i = 0 To total_rows_count
Dim title As String = ds.Tables("announcement").Rows(i).Item("announcement_Title")
'How do I going to make it display on a label and keeps it loop?
lbl_announcement_title.Text += title
'This is not the thing I expect, what I expect is to make it show nicely, like
'the next loop will automatically goes to the next line.
Next
パネル、リストビュー、または何かに入れてループする必要がありますか? ひどく助けが必要です!