0

リストビューでヘッダー、ボディ、フッターを使用してテーブル構造を作成しようとしましたが、正常に機能します。

しかし、layouttemplate にあるフッターで、エラーが発生するコードの下に追加しようとしました。

<LayoutTemplate>
                    <table class="sampletable" cellpadding="0" cellspacing="0">
                        <thead class="tableheader">
                            <tr>
                                <th>
                                    <a>Samples </a>
                                </th>
                            </tr>
                        </thead>
                        <tbody class="tablebody">
                            <tr id="itemplaceHolder" runat="server">
                            </tr>
                        </tbody>
                        <tfoot class="tablefooter">
                            <tr>
                                <td>
                                    <a href='<%:Page.GetRouteUrl("samplelist",null) %>'>more sample</a>
                                </td>
                            </tr>
                        </tfoot>
                    </table>
                   </LayoutTemplate>

レイアウトテンプレートに配置することはできませんか?

エラーは

「コントロールにコード ブロック (つまり <% ... %>) が含まれているため、Controls コレクションを変更できません。」

4

1 に答える 1