Mega Code Archive

 
Categories / ASP.Net Tutorial / ASP Net Controls
 

Wizard template

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs"  Inherits="Temp" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" >   <body>     <form id="form1"        title="FinishNavigationTemplate Example"        runat="server">       <asp:Wizard ID="Wizard1"          Runat="server"          ActiveStepIndex="0"          OnFinishButtonClick="OnFinishButtonClick">         <WizardSteps>           <asp:WizardStep ID="WizardStep1" Runat="server"              Title="Step 1">             <!-- Put UI elements for Step 1 here. -->             This is step one.           </asp:WizardStep>           <asp:WizardStep ID="WizardStep2" Runat="server"              Title="Step 2">             <!-- Put UI elements for Step 2 here. -->             This is step two.           </asp:WizardStep>         </WizardSteps>         <FinishNavigationTemplate>           Please enter your email address if you would like a confirmation email:           <asp:TextBox ID="emailTextBox"              Runat="server">           </asp:TextBox>           &nbsp;<br />           <asp:Button ID="Button1" CommandName="MovePrev"               Runat="server"                Text="Previous" />           <asp:Button ID="Button2" CommandName="MoveComplete"              Runat="server"              Text="Finish" />         </FinishNavigationTemplate>         <HeaderTemplate>           <b>FinishNavigationTemplate Example</b>         </HeaderTemplate>       </asp:Wizard>       <asp:Label ID="myLabel" runat="server"></asp:Label>     </form>   </body> </html> File: Default.aspx.cs using System; using System.Data; using System.Configuration; using System.Collections; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Web.UI.HtmlControls; public partial class Temp : System.Web.UI.Page {     public void OnFinishButtonClick(object sender, EventArgs e)     {         myLabel.Text += "FinishButtonClick called<br/>";      } }