IE Controls:multipage: use combobox to control page index (VB.net) : PageView MultiPage « Components « ASP.Net






IE Controls:multipage: use combobox to control page index (VB.net)

<%@ Page Language=VB Debug=true %>
<%@ Import Namespace="Microsoft.Web.UI.WebControls" %>
<%@ Register TagPrefix="IEControls" 
    Namespace="Microsoft.Web.UI.WebControls" 
    Assembly ="Microsoft.Web.UI.WebControls"
%>
<script runat=server>
Sub ddl1_Changed(Sender As Object, E As EventArgs)
    MyMultiPage.SelectedIndex = ddl1.SelectedItem.Value
End Sub
</SCRIPT>
<HTML>
<HEAD>
<TITLE>Providing Navigation in a MultiPage Control Using a DropDownList</TITLE>
</HEAD>
<BODY LEFTMARGIN="40">
<form runat="server">
<IEControls:multipage 
    id="MyMultiPage"
    runat="server"
    selectedindex=0
    >
    <IEControls:PageView
        id="pv1"
        runat=server
        font-name="Arial"
        font-bold=True
        forecolor="yellow"
        backcolor="darkred"
    >
        Enter your name:<BR>
        <asp:textbox 
        id="txtName" 
        runat=server 
        />    
        <BR>
    </IEControls:PageView>    
    <IEControls:PageView
        id="pv2"
        runat=server
        font-name="Arial"
        font-bold=True
        forecolor="darkred"
        backcolor="yellow"
    >
        Enter your email address:<BR>
        <asp:textbox 
        id="txtEmail" 
        runat=server 
        />    
    </IEControls:PageView>    
    <IEControls:PageView
        id="pv3"
        runat=server
        font-name="Arial"
        font-bold=True
        forecolor="darkblue"
        backcolor="green"
    >
        Enter your password:<BR>
        <asp:textbox 
        id="txtPassword" 
        runat=server 
        />    
    </IEControls:PageView>    
</IEControls:multipage>
<BR><BR>
<asp:dropdownlist
    id="ddl1"
    autopostback="True"
    onselectedindexchanged="ddl1_Changed"
    runat="server"
>
    <asp:listitem value="0">Name</asp:listitem>
    <asp:listitem value="1">Email</asp:listitem>
    <asp:listitem value="2">Password</asp:listitem>
</asp:dropdownlist>
</form>
</BODY>
</HTML>
           
       








Related examples in the same category

1.IEControl: multipage test (C#)
2.Creating a Basic MultiPage Control (VB.net)
3.Adding a PageView Control to a MultiPage Control (VB.net)
4.Adding Controls to a PageView Control in Code (VB.net)