ASP 101 - Active Server Pages 101 wizard.aspx
<%@ Page Language="VB" %>
<script runat="server">
	Sub Page_Load(sender As Object, e As EventArgs)
		' If this is first run set page number to 1
		If Not Page.IsPostBack Then
			PageNumber.Text = 1
		End If
		ShowCurrentPage()
	End Sub
	Sub btnBack_OnClick(sender As Object, e As EventArgs)
		PageNumber.Text = PageNumber.Text - 1
		ShowCurrentPage()
	End Sub
	Sub btnNext_OnClick(sender As Object, e As EventArgs)
		PageNumber.Text = PageNumber.Text + 1
		ShowCurrentPage()
	End Sub
	Sub ShowCurrentPage()
		' Set default state of panels and buttons
		panel1.Visible = False
		panel2.Visible = False
		panel3.Visible = False
		panel4.Visible = False
		btnBack.Visible = True
		btnNext.Visible = True
		' Modify default state depending on current page
		Select Case PageNumber.Text
			Case 1
				panel1.Visible = True
				btnBack.Visible = False
			Case 2
				panel2.Visible = True
				' In case the user is coming back from page 3:
				btnNext.Text = "Next >"
			Case 3
				panel3.Visible = True
				' Let the user know this is the last step:
				btnNext.Text = "Finish"
			Case 4
				' This means we're done... hide buttons and process form!
				panel4.Visible = True
				' This one's up to you:
				' btnBack.Visible = False
				btnNext.Visible = False
				' This is where you would do whatever your form does.
				' I just echo the values back out to our display
				' controls on panel 4.
				litName.Text    = txtName.Text
				litEmail.Text   = txtEmail.Text
				litAddress.Text = txtAddress.Text
				litCity.Text    = txtCity.Text
				litState.Text   = txtState.Text
				litZip.Text     = txtZip.Text
				If Not(rblSex.SelectedItem Is Nothing) Then
					litSex.Text = rblSex.SelectedItem.Text
				End If
				litAge.Text = ddlAge.SelectedItem.Text
		End Select
	End Sub
</script>
<html>
<head>
<title>ASP.NET Wizard (Multi-Page Form) Sample</title>
</head>
<body>
<form runat="server">
<asp:Literal id="PageNumber" runat="server"
	Visible = "False"
/>
<asp:panel id="panel1" runat="server">
	<table>
		<tr>
			<td><strong>Name:</strong></td>
			<td><asp:textbox id="txtName" runat="server" /></td>
		</tr><tr>
			<td><strong>Email:</strong></td>
			<td><asp:textbox id="txtEmail" runat="server" /></td>
		</tr>
	</table>
</asp:panel>
<asp:panel id="panel2" runat="server">
	<table>
		<tr>
			<td><strong>Address:</strong></td>
			<td><asp:textbox id="txtAddress" runat="server" /></td>
		</tr><tr>
			<td><strong>City:</strong></td>
			<td><asp:textbox id="txtCity" runat="server" /></td>
		</tr><tr>
			<td><strong>State:</strong></td>
			<td><asp:textbox id="txtState" runat="server" /></td>
		</tr><tr>
			<td><strong>Zip:</strong></td>
			<td><asp:textbox id="txtZip" runat="server" /></td>
		</tr>
	</table>
</asp:panel>
<asp:panel id="panel3" runat="server">
	<table>
		<tr>
			<td><strong>Sex:</strong></td>
			<td>
				<asp:RadioButtonList id="rblSex" runat="server"
					RepeatDirection = Horizontal
					RepeatLayout    = Flow
				>
					<asp:ListItem>Male</asp:ListItem>
					<asp:ListItem>Female</asp:ListItem>
				</asp:RadioButtonList>
			</td>
		</tr><tr>
			<td><strong>Age:</strong></td>
			<td>
				<asp:DropDownList id="ddlAge" runat="server">
					<asp:ListItem></asp:ListItem>
					<asp:ListItem>< 20</asp:ListItem>
					<asp:ListItem>20 - 29</asp:ListItem>
					<asp:ListItem>30 - 39</asp:ListItem>
					<asp:ListItem>40 - 49</asp:ListItem>
					<asp:ListItem>50 - 59</asp:ListItem>
					<asp:ListItem>60 - 69</asp:ListItem>
					<asp:ListItem>70 - 79</asp:ListItem>
					<asp:ListItem>80 +</asp:ListItem>
				</asp:DropDownList>
			</td>
		</tr>
	</table>
</asp:panel>
<asp:panel id="panel4" runat="server">
	<p><strong>
	Here's what you entered:
	</strong></p>
	<pre>
	<strong>Name:</strong>    <asp:Literal id="litName"    runat="server" />
	<strong>Email:</strong>   <asp:Literal id="litEmail"   runat="server" />
	<strong>Address:</strong> <asp:Literal id="litAddress" runat="server" />
	<strong>City:</strong>    <asp:Literal id="litCity"    runat="server" />
	<strong>State:</strong>   <asp:Literal id="litState"   runat="server" />
	<strong>Zip:</strong>     <asp:Literal id="litZip"     runat="server" />
	<strong>Sex:</strong>     <asp:Literal id="litSex"     runat="server" />
	<strong>Age:</strong>     <asp:Literal id="litAge"     runat="server" />
	</pre>
	<p>
	<a href="<%= Request.ServerVariables("URL") %>">Start Over</a>
	</p>
</asp:panel>
<asp:Button id="btnBack" runat="server"
	Text    = "< Back"
	OnClick = "btnBack_OnClick"
/>
<asp:Button id="btnNext" runat="server"
	Text    = "Next >"
	OnClick = "btnNext_OnClick"
/>
</form>
<hr />
<p>
Click <a href="http://www.asp101.com/samples/wizard_aspx.asp">here</a>
to read about and download the source code.
</p>
</body>
</html>