Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <asp:ListView ID="DocumentsListView" runat="server" EnableModelValidation="True" >
- <EmptyDataTemplate>
- <span>No data was returned.</span>
- </EmptyDataTemplate>
- <ItemTemplate>
- <table id="itemPlaceholder" runat="server" style="margin-top: 20px; width: 680px; border: solid 1px #000000;">
- <tr>
- <td style="width: 180px;">
- <span style="font-size: 18px;">
- <asp:Label ID="NameLabel" runat="server" Text='<%# Container.DataItem %>' /></span><br />
- </td>
- </tr>
- </table>
- </ItemTemplate>
- <LayoutTemplate>
- <%--<table id="itemPlaceholder" runat="server" style="margin-top: 20px;">
- <tr>
- <td>
- <asp:Label ID="NameLabel" runat="server" Text='<%# Container.DataItem %>' /><br />
- </td>
- </tr>
- </table>--%>
- <br />
- <div style="width: 680; text-align: center;">
- <asp:DataPager runat="server" ID="DocumentDataPager" PageSize="10">
- <Fields>
- <asp:NextPreviousPagerField ButtonType="Button" ShowFirstPageButton="True" ShowNextPageButton="False"
- ShowPreviousPageButton="False" LastPageText="Последняя" NextPageText="Следующая" PreviousPageText="Предыдущая" FirstPageText="Первая" />
- <asp:NumericPagerField />
- <asp:NextPreviousPagerField ButtonType="Button" ShowLastPageButton="True" ShowNextPageButton="False"
- ShowPreviousPageButton="False" LastPageText="Последняя" NextPageText="Следующая" PreviousPageText="Предыдущая" FirstPageText="Первая" />
- </Fields>
- </asp:DataPager>
- </div>--
- </LayoutTemplate>
- </asp:ListView>
- А вот так в коде
- List<string> tmpList = new List<string>();
- DocumentsListView.DataSource = tmpList;
- DocumentsListView.DataBind();
Add Comment
Please, Sign In to add comment