带有滚动条的复选框列表
我知道这通常是一个简单的解决方案,但就我而言,情况可能有点不同。我正在使用 C# 客户端代码制作控件。这包含在搜索面板中。我读到的所有内容都说通常我可以将 CheckBoxList 包装在 DIV 标记中。但是,我的搜索字段会根据我需要的选择器自动创建表格。这是表格格式。表中不能有 div。是否有办法覆盖该表格单元格以允许滚动?您有什么建议?
我尝试将复选框列表包装在 div 中并限制 DIV 的高度并将溢出设置为自动,然后滚动。首先,滚动条没有显示。这是因为复选框列表仍然扩展表格单元格以适合整个框。
I know this would normally be an easy solution but in my case the situation may be a little different. I am making a control with C# client side code. This is included in a search panel. Everything I read says normally I could just wrap the CheckBoxList within a DIV tag. However, My search field automatically creates the table based upon what selectors I need. This is in a table format. You cannot have a div within a table. Is there anyway to override that table cell to allow scrolling? What are your suggestions?
I tried wrapping the checkboxlist in a div and limiting the height of the DIV and setting the overflow to auto and then scroll. First off, the scroll bars arent showing. This is because the checkboxlist still extends the table cell to fit the whole box.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您是否考虑过检查
overflow
CSS 属性并将其设置为scroll
?Have you considered checking out the
overflow
CSS property and setting it toscroll
?