是否可以隐藏 ajax TabContainer 上的 Tab Strip?
假设我有一个带有两个选项卡的 ajax TabContainer。由于某些业务逻辑,我们可能会将其中一个选项卡设置为 Visible = false。
在这种情况下,是否可以隐藏顶部的 TabStrip,这样他们就不会只看到一个选项卡?
Suppose I have an ajax TabContainer with two tabs. Due to certain buisness logic, we might set one of the tabs to Visible = false.
In this scenario, is it possible to hide the TabStrip at the top, so that they don't see only one tab?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好的;没有得到任何回复,只是想总结一下我能做的事情:
对于上述情况,我实际上能够通过重新分配其父控件来将一个可见选项卡的内容移动到容器之外,然后重新-添加它需要去的地方(我的示例比平常更复杂一些,因为更新面板位于被移动的代码部分中)
但是,似乎可以通过根据选项卡数量修改其 CSS 类来隐藏 TabStrip应该显示。请参阅http://www.krissteele.net/blogdetails.aspx?id=117 或 http: //cushen.wordpress.com/2007/10/25/how-to-styling-the-asp-net-ajax-tabcontainer-control/ 有关如何修改样式的一些示例。
OK; didn't get any replies, but just wanted to summarize what I was able to do:
For the above situation, I actually was able to move the contents of the one visible tab outside the container by reassigning its parent control, and then re-adding where it needed to go (my example is a little more complicated than usual, due to update panels being in the section of code getting moved)
However, it does seem possible to hide the TabStrip by modifying its CSS class depending on how many tabs should be displayed. See http://www.krissteele.net/blogdetails.aspx?id=117 or http://cushen.wordpress.com/2007/10/25/how-to-styling-the-asp-net-ajax-tabcontainer-control/ for some examples of how to modify the styling.