How do I ad开发者_StackOverflowd a horizontal scrollbar in a listview?
You can wrap the ListView in a div with fixed height, something like this:
<div style=" height:300px; overflow:scroll;">
<asp:ListView ID="ListView2" DataSourceID="EmployeeOCDS" runat="server">
<ItemTemplate>
<tr>
</tr>
</ItemTemplate>
<LayoutTemplate>
<table id="itemPlaceholderContainer" runat="server" border="0" style="">
<tr id="itemPlaceholder" runat="server">
</tr>
</table>
</LayoutTemplate>
</asp:ListView>
</div>
精彩评论