multiview控件,实际上是有点象在c/s开发中很常见的tabcontrol控件,可以在一个页面中,放置多个"view"(我们称为选项卡),比如可以用multiview控件,可以让用户在同一页面中,通过切换到每个选项卡,从而看到要看的内容,而不用每次都重新打开一个新的窗口。然而对Panel 的 Visible属性进行控制也可以完成这个工作,只是说用这个更专业吧!下面看演示:用DropDownList控制选项卡的显示 <form id="form1" runat="server"> <div> multiview控件,实际上是有点象在c/s开发中很常见的tabcontrol控件,可以在一个页面中,放置多个"view"(我们称为选项卡),比如可以用multiview控件,可以让用户在同一页面中,通过切换到每个选项卡,从而看到要看的内容,而不用每次都重新打开一个新的窗口。<br /> 然而对Panel 的 Visible属性进行控制也可以完成这个工作,只是说用这个更专业吧!<br /> <br /> 下面看演示:用DropDownList控制选项卡的显示<br /> <br /> <asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True" OnSelectedIndexChanged="DropDownList1_SelectedIndexChanged"> <asp:ListItem>0</asp:ListItem> <asp:ListItem>1</asp:ListItem> <asp:ListItem>2</asp:ListItem> <asp:ListItem>3</asp:ListItem> </asp:DropDownList><br /> <asp:MultiView ID="MultiView1" runat="server" ActiveViewIndex="0"> <asp:View ID="View1" runat="server"> 000000000000000000000000</asp:View> <asp:View ID="View2" runat="server"> 11111111111111111111111</asp:View> <asp:View ID="View3" runat="server"> 2222222222222222222222</asp:View> <asp:View ID="View4" runat="server"> 33333333333333333333333</asp:View> </asp:MultiView></div> </form> protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e) } 相关文章: 2021-06-10 2022-12-23 2022-01-24 2021-10-01 2021-09-16 2021-06-14 2022-12-23 2022-02-01