当前位置: 移动技术网 > IT编程>开发语言>.net > Asp.net_多选项卡页面的创建

Asp.net_多选项卡页面的创建

2018年11月05日  | 移动技术网IT编程  | 我要评论

广州市妈妈网,联众云新闻登陆,玉女包玉婷

看了很多朋友还不会创建多选项卡的页面,特地总结了一下用法,很简单的一看便知。

 

1.首先下载ajaxcontroltookit包放置在bin目录下,刷新解决方案。

 

2.页面引入(.x)

 

 

[csharp] 

<%@ register assembly="ajaxcontroltoolkit" namespace="ajaxcontroltoolkit" tagprefix="asp" %>  

 

<%@ register assembly="ajaxcontroltoolkit" namespace="ajaxcontroltoolkit" tagprefix="asp" %>

3.控件调用(.aspx) 

 

 

[csharp] 

<asp:tabcontainer id="tc1" runat="server" activetabindex="0" width="100%">  

        <asp:tabpanel id="tp1" runat="server" headertext="选项卡1">  

            <contenttemplate>此处添加页面代码</contenttemplate>  

        </asp:tabpanel>  

        <asp:tabpanel id="tp2" runat="server" headertext="选项卡2">  

            <contenttemplate>此处添加页面代码</contenttemplate>  

        </asp:tabpanel>  

</asp:tabcontainer>  

 

<asp:tabcontainer id="tc1" runat="server" activetabindex="0" width="100%">

        <asp:tabpanel id="tp1" runat="server" headertext="选项卡1">

            <contenttemplate>此处添加页面代码</contenttemplate>

        </asp:tabpanel>

        <asp:tabpanel id="tp2" runat="server" headertext="选项卡2">

            <contenttemplate>此处添加页面代码</contenttemplate>

        </asp:tabpanel>

</asp:tabcontainer>

activetabindex顾名思义是当前激活的选项卡索引,从0开始。 

 

 

 

 

 

 

 

 

【end】

 

如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!! 点击进行留言回复

相关文章:

验证码:
移动技术网