assaultkitty
asked on
Airline10
Error 134 'System.Web.UI.WebControls .Wizard' does not contain a definition for 'ActiveStepType' and no extension method 'ActiveStepType' accepting a first argument of type 'System.Web.UI.WebControls .Wizard' could be found (are you missing a using directive or an assembly reference?) C:\Course Technology\CIS Programming\ASP .NET Programming\Data Files\Chapter.09\Chapter\S kywardAvia tion\Conta ctInfo.asp x.cs 68 25 C:\...\SkywardAviation\
using System;
using System.Collections.Generic ;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (Request.QueryString["flye rID"] == null)
Response.Redirect("Login.a spx");
if (profileForm.ActiveStep.St epType
== WizardStepType.Start)
hiddenPassword.Value = password.Text;
SqlConnection dbConnection = new SqlConnection("Data Source=.\\SQLEXPRESS;Attac hDBFilenam e=C:\\Cour se Technology\\CIS Programming\\ASP .NET Programming\\Data Files\\Chapter.09\\Chapter \\SkywardA viation.md f;Integrat ed Security-True; User Instance=True");
dbConnection.Open();
try
{
SqlCommand sqlCommand = new SqlCommand(
"SELECT * FROM FrequentFlyers WHERE flyerID = "
+ Request.QueryString["flyer ID"], dbConnection);
SqlDataReader userInfo = sqlCommand.ExecuteReader() ;
if (userInfo.Read())
{
firstName.Text = userInfo["first"].ToString ();
lastName.Text = userInfo["last"].ToString( );
telephone.Text = userInfo["phone"].ToString ();
email.Text = userInfo["email"].ToString ();
confirmEmail.Text = userInfo["email"].ToString ();
creditcard.Text = userInfo["cardType"].ToStr ing();
expireMonth.Text = userInfo["expireMonth"].To String();
expireYear.Text = userInfo["expireYear"].ToS tring();
cardnumber.Text = userInfo["cardnumber"].ToS tring();
cardholder.Text = userInfo["cardholder"].ToS tring();
address.Text = userInfo["address"].ToStri ng();
city.Text = userInfo["city"].ToString( );
state.Text = userInfo["state"].ToString ();
zip.Text = userInfo["zip"].ToString() ;
travelerType.Text = userInfo["travelerType"].T oString();
homeAirport.Text = userInfo["homeAirport"].To String();
serviceClass.Text = userInfo["class"].ToString ();
seatPreference.Text = userInfo["seat"].ToString( );
mealRequest.Text = userInfo["meal"].ToString( );
updateOK.Text = "<p>Account successfully updated.</p><p><href='ffCl ubPage.asp x?flyerID= " + Request.QueryString["flyer ID"]
+ "'>Account Profile page</a></p>";
}
else
{
profileForm.Visible =false;
updateErrors.Text = "<p>Invalid frequent flyer number!</p>";
}
userInfo.Close();
}
catch (SqlException exception)
{
Response.Write("<p>Error code "
+ exception.Number
+ "; " + exception.Message + "</p>");
}
dbConnection.Close();
}
protected void Page_LoadComplete(
object sender, EventArgs e)
{
if (profileForm.ActiveStepTyp e
== WizardStepType.Complete)
{
SqlConnection dbConnection = new SqlConnection("Data Source=.\\SQLEXPRESS;Attac hDBFilenam e=C:\\Cour se Technology\\CIS Programming\\ASP .NET Programming\\Data Files\\Chapter.09\\Chapter \\SkywardA viation.md f;Integrat ed Security-True; User Instance=True");
try
{
dbConnection.Open();
SqlCommand sqlCommand = new SqlCommand(
"UPDATE FrequentFlyers SET "
+ "last= '" + lastName.Text + "',"
+ "first = '" + firstName.Text + "',"
+ "phone = '" + telephone.Text + "',"
+ "email = '" + email.Text + "',"
+ "password = '" + hiddenPassword.Value + "',"
+ "cardType = '" + creditcard.Text + "',"
+ "expireMonth = '" + expireMonth.Text + "',"
+ "expireYear = '" + expireYear.Text + "',"
+ "cardnumber = '" + cardnumber.Text + "',"
+ "address = '" + address.Text + "',"
+ "city = '" + city.Text + "',"
+ "state = '" + state.Text + "',"
+ "zip = '" + zip.Text + "',"
+ "travelerType = '" + travelerType.Text + "',"
+ "homeAirport = '" + homeAirport.Text + "',"
+ "class = '" + serviceClass.Text + "',"
+ "seat = '" + seatPreference.Text + "',"
+ "meal = '" + mealRequest.Text + "',"
+ "' WHERE flyerID = "
+ Request.QueryString["flyer ID"], dbConnection);
sqlCommand.ExecuteNonQuery ();
}
catch (SqlException exception)
{
updateOK.Text = "<p>Error code " + exception.Number
+ ": " + exception.Message + "</p>";
}
dbConnection.Close();
}
}
}
<%@ Page Language="C#" Debug="true" AutoEventWireup="true" CodeFile="Login.aspx.cs"
Inherits="_Default" %>
<!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">
<head>
<title>Skyward Airlines</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="styles.css" rel="stylesheet" type="text/css" />
</head>
<body>
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="callback_navtop">
<tr>
<td width="56%" height="60" class="logoname">
Skyward Airlines
</td>
<td width="44%">
</td>
</tr>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="menu">
<tr>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
<div align="center">
<a href="index.htm">Home</a>< /div>
</td>
</tr>
</table>
</td>
<td class="cellbackmenuover">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
<div align="center">
<a href="ffClubPage.aspx"><fo nt color="#20809F">Frequent Flyers</font></a></div>
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuextend" >
</td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td valign="top" bgcolor="#FFFFFF" class="cellbackhmrightexte nd">
<table width="745" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td bgcolor="#FFFFFF">
<table width="745" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="172" rowspan="4" valign="top" class="cellbacksubmenu">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="209" valign="top" class="submenu">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td valign="top" class="cellbackpromobtmext end">
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td height="30" valign="top">
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td height="350" valign="top">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr valign="top">
<td width="12%" height="45">
</td>
<td width="53%">
</td>
<td width="35%">
</td>
</tr>
<tr valign="top">
<td>
</td>
<td>
<h1>
Frequent Flyer Program</h1>
</td>
</tr>
<tr valign="top">
<td>
</td>
<td>
<h2>
Returning Members</h2>
</td>
</tr>
<tr valign="top">
<td>
</td>
<td>
<form id="loginForm" runat="server">
<div>
<asp:TextBox id="account" runat="server"/>
<asp:TextBox id="password" runat="server"/>
<asp:Label id="badLogin" runat="server"/>
</div>
</form>
<h2>
New Members</h2>
<p>
<a href="Registration.aspx">E nroll in Skyward Airlines Frequent Flyer program.</a>
</p>
</td>
<td>
<div class="c3">
<table width="168" border="0" align="right" cellpadding="0" cellspacing="0">
<tr>
<td>
<img src="images/spic_001.jpg" width="168" height="209" alt="Visual formatting image" />
</td>
</tr>
<tr>
<td height="30" valign="top">
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="cellbackhmright">
<tr>
<td width="100%" height="50" bgcolor="#DADADA" class="whiteline">
<table width="100%" border="0" cellspacing="0" cellpadding="6">
<tr>
<td class="promotext">
New Frequent Flyer members can now earn 2,000 Bonus Miles for taking their first
flight.
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</td>
</tr>
<tr valign="top">
<td height="30">
</td>
<td>
</td>
<td>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td valign="top" bgcolor="#FFFFFF" class="btmmenu">
</td>
</tr>
<tr>
<td valign="top" bgcolor="#FFFFFF" class="btmmenu">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr valign="top">
<td width="12%">
</td>
<td width="76%" class="btmmenu">
<a href="index.htm">Home</a> | Frequent Flyers<br />
© 2010 Skyward Airlines
</td>
<td width="12%">
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td valign="top" bgcolor="#FFFFFF" class="btmmenu">
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<p>
</p>
<p>
</p>
<p>
</p>
</body>
</html>
This is the error message that I am getting. Please help me with this one. I am getting better with resolving the issues. I am down to just this one.
This is homeWork.
Active.pdf
using System;
using System.Collections.Generic
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (Request.QueryString["flye
Response.Redirect("Login.a
if (profileForm.ActiveStep.St
== WizardStepType.Start)
hiddenPassword.Value = password.Text;
SqlConnection dbConnection = new SqlConnection("Data Source=.\\SQLEXPRESS;Attac
dbConnection.Open();
try
{
SqlCommand sqlCommand = new SqlCommand(
"SELECT * FROM FrequentFlyers WHERE flyerID = "
+ Request.QueryString["flyer
SqlDataReader userInfo = sqlCommand.ExecuteReader()
if (userInfo.Read())
{
firstName.Text = userInfo["first"].ToString
lastName.Text = userInfo["last"].ToString(
telephone.Text = userInfo["phone"].ToString
email.Text = userInfo["email"].ToString
confirmEmail.Text = userInfo["email"].ToString
creditcard.Text = userInfo["cardType"].ToStr
expireMonth.Text = userInfo["expireMonth"].To
expireYear.Text = userInfo["expireYear"].ToS
cardnumber.Text = userInfo["cardnumber"].ToS
cardholder.Text = userInfo["cardholder"].ToS
address.Text = userInfo["address"].ToStri
city.Text = userInfo["city"].ToString(
state.Text = userInfo["state"].ToString
zip.Text = userInfo["zip"].ToString()
travelerType.Text = userInfo["travelerType"].T
homeAirport.Text = userInfo["homeAirport"].To
serviceClass.Text = userInfo["class"].ToString
seatPreference.Text = userInfo["seat"].ToString(
mealRequest.Text = userInfo["meal"].ToString(
updateOK.Text = "<p>Account successfully updated.</p><p><href='ffCl
+ "'>Account Profile page</a></p>";
}
else
{
profileForm.Visible =false;
updateErrors.Text = "<p>Invalid frequent flyer number!</p>";
}
userInfo.Close();
}
catch (SqlException exception)
{
Response.Write("<p>Error code "
+ exception.Number
+ "; " + exception.Message + "</p>");
}
dbConnection.Close();
}
protected void Page_LoadComplete(
object sender, EventArgs e)
{
if (profileForm.ActiveStepTyp
== WizardStepType.Complete)
{
SqlConnection dbConnection = new SqlConnection("Data Source=.\\SQLEXPRESS;Attac
try
{
dbConnection.Open();
SqlCommand sqlCommand = new SqlCommand(
"UPDATE FrequentFlyers SET "
+ "last= '" + lastName.Text + "',"
+ "first = '" + firstName.Text + "',"
+ "phone = '" + telephone.Text + "',"
+ "email = '" + email.Text + "',"
+ "password = '" + hiddenPassword.Value + "',"
+ "cardType = '" + creditcard.Text + "',"
+ "expireMonth = '" + expireMonth.Text + "',"
+ "expireYear = '" + expireYear.Text + "',"
+ "cardnumber = '" + cardnumber.Text + "',"
+ "address = '" + address.Text + "',"
+ "city = '" + city.Text + "',"
+ "state = '" + state.Text + "',"
+ "zip = '" + zip.Text + "',"
+ "travelerType = '" + travelerType.Text + "',"
+ "homeAirport = '" + homeAirport.Text + "',"
+ "class = '" + serviceClass.Text + "',"
+ "seat = '" + seatPreference.Text + "',"
+ "meal = '" + mealRequest.Text + "',"
+ "' WHERE flyerID = "
+ Request.QueryString["flyer
sqlCommand.ExecuteNonQuery
}
catch (SqlException exception)
{
updateOK.Text = "<p>Error code " + exception.Number
+ ": " + exception.Message + "</p>";
}
dbConnection.Close();
}
}
}
<%@ Page Language="C#" Debug="true" AutoEventWireup="true" CodeFile="Login.aspx.cs"
Inherits="_Default" %>
<!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">
<head>
<title>Skyward Airlines</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="styles.css" rel="stylesheet" type="text/css" />
</head>
<body>
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="callback_navtop">
<tr>
<td width="56%" height="60" class="logoname">
Skyward Airlines
</td>
<td width="44%">
</td>
</tr>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="menu">
<tr>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
<div align="center">
<a href="index.htm">Home</a><
</td>
</tr>
</table>
</td>
<td class="cellbackmenuover">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
<div align="center">
<a href="ffClubPage.aspx"><fo
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuunder">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="txtmenu">
<img src="images/spacer.gif" width="95" height="1" alt="Formatting image" />
</td>
</tr>
<tr>
<td class="txtmenu">
</td>
</tr>
</table>
</td>
<td class="cellbackmenuextend"
</td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td valign="top" bgcolor="#FFFFFF" class="cellbackhmrightexte
<table width="745" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td bgcolor="#FFFFFF">
<table width="745" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="172" rowspan="4" valign="top" class="cellbacksubmenu">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="209" valign="top" class="submenu">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td valign="top" class="cellbackpromobtmext
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td height="30" valign="top">
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td height="350" valign="top">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr valign="top">
<td width="12%" height="45">
</td>
<td width="53%">
</td>
<td width="35%">
</td>
</tr>
<tr valign="top">
<td>
</td>
<td>
<h1>
Frequent Flyer Program</h1>
</td>
</tr>
<tr valign="top">
<td>
</td>
<td>
<h2>
Returning Members</h2>
</td>
</tr>
<tr valign="top">
<td>
</td>
<td>
<form id="loginForm" runat="server">
<div>
<asp:TextBox id="account" runat="server"/>
<asp:TextBox id="password" runat="server"/>
<asp:Label id="badLogin" runat="server"/>
</div>
</form>
<h2>
New Members</h2>
<p>
<a href="Registration.aspx">E
</p>
</td>
<td>
<div class="c3">
<table width="168" border="0" align="right" cellpadding="0" cellspacing="0">
<tr>
<td>
<img src="images/spic_001.jpg" width="168" height="209" alt="Visual formatting image" />
</td>
</tr>
<tr>
<td height="30" valign="top">
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="cellbackhmright">
<tr>
<td width="100%" height="50" bgcolor="#DADADA" class="whiteline">
<table width="100%" border="0" cellspacing="0" cellpadding="6">
<tr>
<td class="promotext">
New Frequent Flyer members can now earn 2,000 Bonus Miles for taking their first
flight.
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</td>
</tr>
<tr valign="top">
<td height="30">
</td>
<td>
</td>
<td>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td valign="top" bgcolor="#FFFFFF" class="btmmenu">
</td>
</tr>
<tr>
<td valign="top" bgcolor="#FFFFFF" class="btmmenu">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr valign="top">
<td width="12%">
</td>
<td width="76%" class="btmmenu">
<a href="index.htm">Home</a> | Frequent Flyers<br />
© 2010 Skyward Airlines
</td>
<td width="12%">
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td valign="top" bgcolor="#FFFFFF" class="btmmenu">
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<p>
</p>
<p>
</p>
<p>
</p>
</body>
</html>
This is the error message that I am getting. Please help me with this one. I am getting better with resolving the issues. I am down to just this one.
This is homeWork.
Active.pdf
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Airline1, ... Airline10 - IMHO you could do with having a better title to your questions than that. Experts get an email with that as the info concerning your question
ASKER
This worked perfectly. Thank you. I am almost finished with program. Then I have to start the project. Wish me good luck. It has to do with regular expression!