1

なぜこれが機能しないのかわかりません。バックエンド コードからテーブル ヘッダー セクションを作成しようとしていますが、すべてが tbody に入ります。

        Dim output As New Web.UI.WebControls.Table

        'Create the header row
        Dim hRow As New Web.UI.WebControls.TableHeaderRow
        hRow.TableSection = Web.UI.WebControls.TableRowSection.TableHeader
        hRow.Controls.Add(New Web.UI.WebControls.TableHeaderCell)

        For Each d As GridDate In Dates
            Dim hCell As New Web.UI.WebControls.TableHeaderCell
            hCell.Text = d.Value
            hRow.Controls.Add(hCell)
        Next
        output.Controls.Add(hRow)

ヘッダー行を作成し、セクション プロパティをヘッダーに設定しているにもかかわらず、結果は tbody の下のすべてです。私は何を間違っていますか?

ここに画像の説明を入力

4

2 に答える 2