0% found this document useful (0 votes)
11 views

Project 1

Uploaded by

johnikea9
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

Project 1

Uploaded by

johnikea9
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 39

Practical 1

Q. 1) A
Aim: Write a program to take 4 input from user and perform arithmetic operation.
Code:
using System;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
double a, b, c, d;
Console.WriteLine("Enter a first number:");
a = Convert.ToInt32(Console.ReadLine());
Console.WriteLine("Enter a second number:");
b = Convert.ToInt32(Console.ReadLine());
Console.WriteLine("Enter a Third number:");
c = Convert.ToInt32(Console.ReadLine());
Console.WriteLine("Enter a Fourth number:");
d = Convert.ToInt32(Console.ReadLine());
Console.WriteLine("Addition of 4 number:" + (a + b + c + d));
Console.WriteLine("Addition of 4 number:" + (a - b - c - d));
Console.WriteLine("Addition of 4 number:" + (a * b * c * d));
Console.WriteLine("Addition of 4 number:" + (a / b / c / d));
Console.ReadLine();
}
}
}
Output:

Q.1) B
Aim: If you have 2 integer store in variable var1 and var2,What Boolean test ,can you perform to
see if one or the other(but not both).
Code:
using System;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
double var1,var2;

Om Mishra (69)
TYIT B
Console.WriteLine("Enter a first number:");
var1 = Convert.ToInt32(Console.ReadLine());
Console.WriteLine("Enter a second number:");
var2 = Convert.ToInt32(Console.ReadLine());
if (var1 > 10 && var2 > 10)
{
Console.WriteLine(" both number are greaer than 10 ");
}
else if (var2 > 10)
{
Console.WriteLine("second number are greater than 10."+"first Number is less than
10");
}
else if (var1 > 10)
{
Console.WriteLine("first number are greater than 10." + "second Number is less than
10");
}
else {
Console.WriteLine("Both number are less than 10");
}
Console.ReadLine();
}
}
}
Output:

Q.1) C
Aim: Check whether number is prime or not
Code:
using System;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
Console.Write("Enter a Number : ");
int number = int.Parse(Console.ReadLine());
bool IsPrime = true;
for (int i = 2; i < number / 2; i++)
{
if (number % i == 0)
{
IsPrime = false;
break;
}
}
if (IsPrime)

Om Mishra (69)
TYIT B
{
Console.Write("Number is Prime.");
}
else
{
Console.Write("Number is not Prime.");
}
Console.ReadLine();
}
}
}
Output:

Q.1) D
Aim: Write a program to print Fibonacci series
Code:
using System;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
int n1=0,n2=1,n3,i,number;
Console.Write("Enter the number of elements: ");
number = int.Parse(Console.ReadLine());
Console.Write(n1+" "+n2+" ");
for (i = 2; i < number; ++i)
{
n3 = n1 + n2;
Console.Write(n3 + " ");
n1 = n2;
n2 = n3;
}
Console.ReadLine();
}
}
} Output:

Q.1) E
Aim: Write a program to print reverse of number.
Code:

using System;
public class ReverseExample
{
public static void Main(string[] args)

Om Mishra (69)
TYIT B
{
int n, reverse = 0, rem;
Console.Write("Enter a number: ");
n = int.Parse(Console.ReadLine());
while (n != 0)
{
rem = n % 10;
reverse = reverse * 10 + rem;
n /= 10;
}
Console.Write("Reversed Number: " + reverse);
Console.ReadLine();
}
}
Output:

Q.1) F
Aim: Writ a program to perform string class function.
Code:
using System;
public class ReverseExample
{
public static void Main(string[] args)
{
string text = "Ice Cream";
Console.WriteLine(text.Trim());
Console.WriteLine(text.PadLeft(12, '@'));
Console.WriteLine(text.PadRight(12, '*'));
Console.WriteLine(text.ToLower());
Console.WriteLine(text.ToUpper());
Console.WriteLine(text.Substring(3));
Console.WriteLine(text.Replace("C","S"));
Console.WriteLine(text.StartsWith("The"));
Console.WriteLine(text.EndsWith("Cream"));
Console.ReadLine();
}
}
Output:

Om Mishra (69)
TYIT B
Practical 2
Q.2) A
Aim: Create a calculator using Asp.net Web application.
Code:
Default.aspx :
<%@ Page Title="Home Page" Language="C#" MasterPageFile="~/Site.master"
AutoEventWireup="true"
CodeFile="Default.aspx.cs" Inherits="_Default" %>

<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">


</asp:Content>
<asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent">
<asp:Label ID="Label1" runat="server" Text="Enter a first Number:"></asp:Label>
<asp:TextBox ID="TextBox3" runat="server"></asp:TextBox>
<br />
<asp:Label ID="Label2" runat="server" Text="Enter a second Number:"></asp:Label>
&nbsp;
<asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>
<br />

&nbsp;&nbsp;&nbsp;
<asp:Button ID="Button4" runat="server" onclick="Button4_Click" Text="Add" />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Sub" />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;
<asp:Button ID="Button2" runat="server" onclick="Button2_Click" Text="Mul" />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;
<asp:Button ID="Button3" runat="server" onclick="Button3_Click" Text="Div" />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<br />
<br />
<asp:Label ID="Label3" runat="server" Text="Result"></asp:Label>

<asp:TextBox ID="TextBox4" runat="server"></asp:TextBox>


<br />

</asp:Content>

Default.aspx.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class _Default : System.Web.UI.Page


{
protected void Page_Load(object sender, EventArgs e)
{

}
protected void Button1_Click(object sender, EventArgs e)
{
int Result = int.Parse(TextBox3.Text) - int.Parse(TextBox2.Text);

Om Mishra (69)
TYIT B
TextBox4.Text = Result.ToString();
}
protected void Button4_Click(object sender, EventArgs e)
{
int Result = int.Parse(TextBox3.Text) + int.Parse(TextBox2.Text);
TextBox4.Text = Result.ToString();
}
protected void Button2_Click(object sender, EventArgs e)
{
int Result = int.Parse(TextBox3.Text) * int.Parse(TextBox2.Text);
TextBox4.Text = Result.ToString();
}
protected void Button3_Click(object sender, EventArgs e)
{
int Result = int.Parse(TextBox3.Text) / int.Parse(TextBox2.Text);
TextBox4.Text = Result.ToString();
}
}

Output:

Q. 2 B Aim : Take student details from user and display that record
in table control .
Default.aspx (Source)
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs"
Inherits="TableCells.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 runat="server">
<title></title>
<style type="text/css">
.style1
{
width: 100%;
}
.style2
{

Om Mishra (69)
TYIT B
width: 214px;
}
</style>
</head>
<body>
<form id="form1" runat="server">
<div>
<h1>Student Form</h1>
<table class="style1">
<tr>
<td class="style2">
<asp:Label ID="Label1" runat="server" Text="Student Name :"></asp:Label>
</td>
<td>
<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
</td>
</tr>
<tr>
<td class="style2">
<asp:Label ID="Label2" runat="server" Text="Student Id :"></asp:Label>
</td>
<td>
<asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>
</td>
</tr>
<tr>
<td class="style2">
<asp:Label ID="Label3" runat="server" Text="Course Name :"></asp:Label>
</td>
<td>
<asp:TextBox ID="TextBox3" runat="server"></asp:TextBox>
</td>
</tr>
<tr>
<td class="style2">
<asp:Label ID="Label4" runat="server" Text="DOB :"></asp:Label>
</td>
<td>
<asp:TextBox ID="TextBox4" runat="server"></asp:TextBox>
</td>
</tr>
<tr>
<td class="style2">
&nbsp;</td>
<td>
<asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Submit"
/>
</td>
</tr>
<tr>
<td class="style2">
<asp:Table ID="Table1" runat="server" BorderStyle="Solid" Width="355px">
<asp:TableRow runat="server">
<asp:TableCell runat="server" BorderStyle="Solid">student
name</asp:TableCell>
<asp:TableCell runat="server" BorderStyle="Solid">student
id</asp:TableCell>
<asp:TableCell runat="server" BorderStyle="Solid">course name
</asp:TableCell>

Om Mishra (69)
TYIT B
<asp:TableCell runat="server" BorderStyle="Solid">dob</asp:TableCell>
</asp:TableRow>
</asp:Table>
</td>
<td>
&nbsp;</td>
</tr>
</table>
</div>
</form>
</body>
</
html>

Default.aspx.cs
using System; using
System.Collections.Generic;
using System.Linq; using
System.Web; using
System.Web.UI;
using System.Web.UI.WebControls;

namespace TableCells
{
public partial class Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)

{
}

protected void Button1_Click(object sender, EventArgs e)


{
string sname =
TextBox1.Text; string sid =
TextBox2.Text; string
scourse = TextBox3.Text;
string dob = TextBox4.Text;

TableRow row = new TableRow();

TableCell namecell = new TableCell();


TableCell idcell = new TableCell();
TableCell coursecell = new TableCell();
TableCell dobcell = new TableCell();

namecell.Text =
sname; idcell.Text =
sid; coursecell.Text
= scourse;
dobcell.Text = dob;

row.Cells.Add(namecell);
row.Cells.Add(idcell);
row.Cells.Add(coursecell);
row.Cells.Add(dobcell);

Table1.Rows.Add(row);

Om Mishra (69)
TYIT B
TextBox1.Text = string.Empty;
TextBox2.Text = string.Empty;
TextBox3.Text = string.Empty;
TextBox4.Text = string.Empty;
}
}
}

Default.aspx (Design)

Output
:

PRACTICAL 3
Q.3 A
Aim : Implement a calendar control to display dates and time formats
.
Default.aspx (Source)
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs"
Inherits="Calendarformats.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 runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>

<asp:Calendar ID="Calendar1" runat="server"

Om Mishra (69)
TYIT B
onselectionchanged="Calendar1_SelectionChanged"></asp:Calendar>

</div>
</form>
</body>
</html>

Default.aspx (Design)

Default.aspx.cs
using System;
using
System.Collections.Generic;
using System.Linq; using
System.Web; using
System.Web.UI;
using System.Web.UI.WebControls;

namespace Calendarformats
{
public partial class Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

protected void Calendar1_SelectionChanged(object sender, EventArgs e)


{
Response.Write(Calendar1.SelectedDate.ToString());
Response.Write("<br>" + Calendar1.SelectedDate.ToLongDateString());
Response.Write("<br>" + Calendar1.SelectedDate.ToLongTimeString());
Response.Write("<br>" + Calendar1.SelectedDate.ToShortDateString());
Response.Write("<br>" + Calendar1.SelectedDate.ToShortTimeString());
Response.Write("<br>" + Calendar1.SelectedDate.ToUniversalTime());
}
}
}

Output :

Om Mishra (69)
TYIT B
PRACTICAL 4
Q.4 A
Aim : Create a registration form validations and print submitted
successful message .

Default.aspx (Source)
<%@ Page Language="C#" AutoEventWireup="true"
CodeFile="Default.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 runat="server">
<title></title>

Om Mishra (69)
TYIT B
<style type="text/css">
.style1
{
width: 100%;
}
.style2
{
width: 165px;
}
.style3
{
width: 301px;
}
</style>
</head>
<body style="width: 1399px">
<form id="form1" runat="server">
<table class="style1">
<tr>
<td class="style2">
Username:</td>
<td class="style3">
<asp:TextBox ID="TextBox1"
runat="server"></asp:TextBox>
</td>
<td>
<asp:RequiredFieldValidator
ID="RequiredFieldValidator1" runat="server"
ControlToValidate="TextBox1"
ErrorMessage="please enter full name"
ForeColor="Red"></asp:RequiredFieldValidator>
</td>
</tr>

Om Mishra (69)
TYIT B
<tr>
<td class="style2">
Passward:</td>
<td class="style3">
<asp:TextBox ID="TextBox2" runat="server"
TextMode="Password"></asp:TextBox>
</td>
<td>
<asp:RequiredFieldValidator
ID="RequiredFieldValidator2" runat="server"
ControlToValidate="TextBox2" ErrorMessage="Enter
a strong passwprd"
ForeColor="Red"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td class="style2">
Confirm Password:</td>
<td class="style3">
<asp:TextBox ID="TextBox3" runat="server"
TextMode="Password"></asp:TextBox>
</td>
<td>
<asp:RequiredFieldValidator
ID="RequiredFieldValidator3" runat="server"
ControlToValidate="TextBox3"
ErrorMessage="Passward should be same"
ForeColor="Red"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator1"
runat="server"
ControlToCompare="TextBox2"
ControlToValidate="TextBox3" Display="None"
ErrorMessage="Both Passward shoub be same"
ForeColor="Red"></asp:CompareValidator>
</td>

Om Mishra (69)
TYIT B
</tr>
<tr>
<td class="style2">
Email:</td>
<td class="style3">
<asp:TextBox ID="TextBox5"
runat="server"></asp:TextBox>
</td>
<td>
<asp:RegularExpressionValidator
ID="RegularExpressionValidator1" runat="server"
ControlToValidate="TextBox5"
ErrorMessage="Please Enter correct email"
ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\
w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
</td>
</tr>
<tr>
<td class="style2">
Country:</td>
<td class="style3">
<asp:DropDownList ID="DropDownList1" runat="server">
<asp:ListItem Value="Ind">Select
Country</asp:ListItem>
<asp:ListItem Value="Usa"></asp:ListItem>
<asp:ListItem Value="Ind"></asp:ListItem>
<asp:ListItem></asp:ListItem>
</asp:DropDownList>
</td>
<td>
&nbsp;</td>
</tr>
<tr>
<td class="style2">

Om Mishra (69)
TYIT B
<asp:Label ID="Label1" runat="server"
Text="Label"></asp:Label>
</td>
<td class="style3">
<asp:Button ID="Button1" runat="server"
onclick="Button1_Click" Text="Submit" />
</td>
<td>
&nbsp;</td>
</tr>
</table>
</form>
</body>
</html>

Default.aspx (Design)

Default.aspx.cs

using System;

using System.Collections.Generic;

using System.Linq;

using System.Web;

using System.Web.UI;

using System.Web.UI.WebControls;

Om Mishra (69)
TYIT B
public partial class _Default : System.Web.UI.Page

protected void Page_Load(object sender, EventArgs e)

protected void Button1_Click(object sender, EventArgs e)

Label1.Text = "Successfully Registered";

Output :

Q.4 B
Aim : Create 3 advertisement banners , for each banner , provide
navigate link .
Default.aspx (Source)
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs"
Inherits="_Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"

Om Mishra (69)
TYIT B
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>

<asp:AdRotator ID="AdRotator1" runat="server"


AdvertisementFile="~/XMLFile.xml" />

</div>
</form>
</body>
</html>

XMLFILE
<?xml version="1.0" encoding="utf-8" ?>
<Advertisements>
<Ad>
<ImageUrl>http://localhost:57387/WebSite13/money.jpg</ImageUrl>
<AlternateText>Image1</AlternateText>
<NavigateUrl>https://open.spotify.com/</NavigateUrl>
</Ad>
<Ad>
<ImageUrl>http://localhost:57387/WebSite13/nature.jpg</ImageUrl>
<AlternateText>wait</AlternateText>
<NavigateUrl>https://www.flipkart.com/</NavigateUrl>
</Ad>
<Ad>
<ImageUrl>http://localhost:57387/WebSite13/flower.jpg</ImageUrl>
<AlternateText>wait</AlternateText>
<NavigateUrl>https://www.amazon.in/</NavigateUrl>
</Ad>
</Advertisements>
Output:

Om Mishra (69)
TYIT B
PRACTICAL 5
Q.5 A
Aim : Take input from user to check a number is positive and apply
required exception handling .
Default.aspx (Source)

using System; using


System.Collections.Generic;
using System.Linq; using
System.Web; using
System.Web.UI;
using System.Web.UI.WebControls;

namespace exceptionhandling
{
class NegativeException : Exception
{
public NegativeException(string msg)
: base(msg)
{
}
}
public partial class WebForm1 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

protected void Button1_Click(object sender, EventArgs e)


{
int num;
try

Om Mishra (69)
TYIT B
{
num =
int.Parse(TextBox1.Text); if
(num < 0)
{
throw new NegativeException("Negative Number");
}
else
{
Label1.Text = "Positive Number";
}
}
catch (Exception ex)
{
Label1.Text = ex.Message;
}
}
}
}

Output :

Q.5 B
Aim : Create a tree view control .
Default.aspx (Source)
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs"
Inherits="Treeviewcontrolpractical.WebForm1" %>

Om Mishra (69)
TYIT B
<!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 runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>

<asp:TreeView ID="TreeView1" runat="server">


<Nodes>
<asp:TreeNode Text="Examination" Value="Examination">
<asp:TreeNode Text="FY" Value="FY">
<asp:TreeNode Text="ATKT" Value="ATKT"></asp:TreeNode>
<asp:TreeNode Text="REGULAR" Value="REGULAR"></asp:TreeNode>
</asp:TreeNode>
<asp:TreeNode Text="SY" Value="SY">
<asp:TreeNode Text="ATKT" Value="ATKT"></asp:TreeNode>
<asp:TreeNode Text="REGULAR" Value="REGULAR"></asp:TreeNode>
</asp:TreeNode>
<asp:TreeNode Text="TY" Value="TY">
<asp:TreeNode Text="ATKT" Value="ATKT"></asp:TreeNode>
<asp:TreeNode Text="REGULAR" Value="REGULAR"></asp:TreeNode>
</asp:TreeNode>
</asp:TreeNode>
<asp:TreeNode Text="Admission" Value="Admission">
<asp:TreeNode Text="FY" Value="FY"></asp:TreeNode>
<asp:TreeNode Text="SY" Value="SY"></asp:TreeNode>
<asp:TreeNode Text="TY" Value="TY"></asp:TreeNode>
</asp:TreeNode>
</Nodes>
</asp:TreeView>

</div>
</form>
</body>
</html>

Default.aspx (Design)

FY.aspx
:

Om Mishra (69)
TYIT B
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="FY.aspx.cs"
Inherits="Treeviewcontrolpractical.FY" %>

<!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 runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
<h2>FYIT EXAMINATION APPLICATION </h2>
</div>
</form>
</body>
</html>

ATKT.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ATKT.aspx.cs"
Inherits="Treeviewcontrolpractical.ATKT" %>

<!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 runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
<h4>ATKT APPLICATION</h4>
<asp:Label ID="Label1" runat="server" Text="Name :"></asp:Label>
&nbsp;<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
<br />
<br />
<asp:Label ID="Label2" runat="server" Text="StudentID:"></asp:Label>
&nbsp;<asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>

</div>
</form>
</body>
</html>

REGULAR.aspx :
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="REGULAR.aspx.cs"
Inherits="Treeviewcontrolpractical.REGULAR" %>

<!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 runat="server">
<title></title>

Om Mishra (69)
TYIT B
</head>
<body>
<form id="form1" runat="server">
<div>
<h4>REGULAR APPLICATION</h4>
<asp:Label ID="Label1" runat="server" Text="Name :"></asp:Label>
&nbsp;<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
<br />
<br />
<asp:Label ID="Label2" runat="server" Text="StudentID:"></asp:Label>
&nbsp;<asp:TextBox ID="TextBox2"
runat="server"></asp:TextBox> </div>
</form>
</body>
</html>

OUTPUT :

Om Mishra (69)
TYIT B
Practical 6
Q.6) A
Aim: Perform a Hierarchical Inheritance.
Code:
Webform1.aspx(source)
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs"
Inherits="WebApplication11.WebForm1" %>

<!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 runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>

Hierarchical Inheritance<br />


<br />
<br />
<asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Submit" />
<br />
<br />
<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
<br />
<br />
<asp:Label ID="Label2" runat="server" Text="Label"></asp:Label>
<br />
<br />
<asp:Label ID="Label3" runat="server" Text="Label"></asp:Label>
<br />
<br />
<asp:Label ID="Label4" runat="server" Text="Label"></asp:Label>
<br />

</div>
</form>
</body>
</html>

Webform1.apsx.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

Om Mishra (69)
TYIT B
using System.Web.UI;
using System.Web.UI.WebControls;

namespace WebApplication11
{
public partial class WebForm1 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

protected void Button1_Click(object sender, EventArgs e)


{
Son obj = new Son();
Daughter obj1 = new Daughter();
Label1.Text = Convert.ToString(obj.phone());
Label2.Text = Convert.ToString(obj.Home());
Label3.Text = Convert.ToString(obj1.jewell());
Label4.Text = Convert.ToString(obj1.Home());

}
public class Father {
public string Home() {
return ("This is from father class");
}
}
public class Son:Father
{
public string phone(){
return("phone belong to son");
}
}
public class Daughter:Father
{
public string jewell()
{
return("jewellery belongs to daughter");
}
}
}
}

Output:

Om Mishra (69)
TYIT B
Practical 7
Q.7) A
Aim: Perform a Parametrize constructor .
Code:
Webform1.aspx
<%@ Page Title="Home Page" Language="C#" MasterPageFile="~/Site.master"
AutoEventWireup="true"
CodeBehind="Default.aspx.cs" Inherits="WebApplication12._Default" %>

<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">


</asp:Content>
<asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent">
<h2>
Welcome to ASP.NET!
</h2>
<p>
To learn more about ASP.NET visit <a href="http://www.asp.net" title="ASP.NET
Website">www.asp.net</a>.
</p>
<p>
You can also find <a href="http://go.microsoft.com/fwlink/?
LinkID=152368&amp;clcid=0x409"
title="MSDN ASP.NET Docs">documentation on ASP.NET at MSDN</a>.
</p>
</asp:Content>

Webform1.aspx.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace WebApplication12
{
public partial class WebForm1 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)

Om Mishra (69)
TYIT B
{

protected void Button1_Click(object sender, EventArgs e)


{
parametrize obj = new parametrize("asp", "2024");
Label1.Text=("I am "+obj.name+" "+obj.year+"from parametrize constructor");
}
public class parametrize
{
public string name,year;
public parametrize(string name,string year)
{
this.name = name;

this.year = year;
}
}
}
}
Output:

Practical 8
Q.8) A
Aim: Create Database connection
Code:
Webform.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs"
Inherits="WebApplication14.WebForm1" %>

<!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 runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>

<asp:Label ID="Label1" runat="server" Text="username:"></asp:Label>


<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
<br />
<br />
<br />
<br />
<asp:Label ID="Label2" runat="server" Text="password:"></asp:Label>

Om Mishra (69)
TYIT B
<asp:TextBox ID="TextBox2" runat="server" TextMode="Password"></asp:TextBox>
<br />
<br />
<br />
<br />
<asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="login" />
<br />

</div>
</form>
</body>
</html>

Webform1.aspx.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Data;
using System.Data.SqlClient;

using System.Web.UI;
using System.Web.UI.WebControls;

namespace WebApplication14
{
public partial class WebForm1 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

protected void Button1_Click(object sender, EventArgs e)


{
SqlConnection con = new SqlConnection(@"Data Source=KUNALS\SQLEXPRESS;Initial
Catalog=ASP;Integrated Security=True");

try
{
con.Open();
SqlCommand cmd = new SqlCommand("select count(*) from login where username='"
+ TextBox1.Text + "' and password='" + TextBox2.Text + "' ", con);
SqlDataAdapter sda = new SqlDataAdapter(cmd);
DataTable dt = new DataTable();
sda.Fill(dt);
cmd.ExecuteNonQuery();

Om Mishra (69)
TYIT B
if (dt.Rows[0][0].ToString() == "1")
{
Response.Write("login successfully");
//Response.Redirect("WebForm1.aspx");
}
else
{
Response.Write("failed");
}

}
catch (Exception ex)
{
Response.Write(ex.Message);
}

}
}
}
Output:

Om Mishra (69)
TYIT B
Project
Code:
Webform1.aspx
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs"
Inherits="book.WebForm1" %>

<!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 runat="server">
<title></title>
<style type="text/css">
body {
background-image: url('11.png');

}
</style>
</head>
<body style="height: 800px; width: 1600px; margin-left: 20px; margin-top: 26px">
<form id="form1" runat="server">
<div>

<br />

</div>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
<p style="height: 49px; margin-top: 85px">
<asp:Button ID="Button1" runat="server" ForeColor="#3366FF" Height="69px"
onclick="Button1_Click"
style="font-weight: 700; color: #FFFFFF; font-size: x-large; text-align: center; margin-left:
160px; margin-top: 461px; background-color: #CC33FF"
Text="Shop Now" Width="314px" />
</p>
</form>
</body>
</html>

Webform1.aspx.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace book
{
public partial class WebForm1 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

Om Mishra (69)
TYIT B
protected void ImageButton1_Click(object sender, ImageClickEventArgs
e)
{

protected void Button1_Click(object sender, EventArgs e)


{
Response.Redirect("login.aspx");
}

}
}

Login.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="login.aspx.cs"
Inherits="book.login" %>

<!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 runat="server">
<title></title>
<style type="text/css">
body {
background-image: url('kkk.png');

}
#form1
{
height: 402px;
width: 443px;
margin-left: 557px;
margin-top: 135px;
background-color: #33CCFF;
}
.style1
{
font-family: Arial;
color: #CC33FF;
}
</style>

</head>
<body>
<form id="form1" runat="server">
&nbsp;<br />
<br />
<strong>
<br />
<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp; &nbsp;
</strong><span class="style1">
<strong style="font-size: x-large; font-weight: 700; background-color:
#FFFFFF">&nbsp;&nbsp;&nbsp; Create Account&nbsp;
<br />
<br />

Om Mishra (69)
TYIT B
<br />
User Name:<asp:TextBox ID="TextBox3" runat="server"
CausesValidation="True"
Height="23px" Width="182px" placeholder=" Enter User
Name"></asp:TextBox>
<br />
<br />
Email:<asp:TextBox ID="TextBox2" runat="server" CausesValidation="True"
Height="20px" Width="180px" placeholder="[email protected]"></asp:TextBox>
<br />
<br />
Passward:
<asp:TextBox ID="TextBox1" runat="server" CausesValidation="True"
Height="22px"
ontextchanged="TextBox1_TextChanged" Width="155px"
placeholder="Password"
TextMode="Password"></asp:TextBox>
&nbsp;<br />
<br />
<br />
<br />
</strong></span>
<p class="style1">
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;</p>
<span class="style1">
<strong style="font-size: x-large; font-weight: 700; background-color:
#FFFFFF">
<asp:Button ID="Button1" runat="server" CssClass="style1" Height="49px"
onclick="Button1_Click" style="margin-left: 0px" Text="Register"
Width="321px" />
</strong></span>
<p class="style1">
<asp:Label ID="Label1" runat="server"></asp:Label>
</p>
</form>
</body>
</html>

Login.aspx.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace book
{
public partial class login : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

protected void TextBox1_TextChanged(object sender, EventArgs e)


{

Om Mishra (69)
TYIT B
}

protected void Button1_Click(object sender, EventArgs e)


{
Label1.Text = "Your Account has created";
Response.Redirect("WebForm2.aspx");

}
}
}

Webform2.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs"
Inherits="book.WebForm2" %>

<!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 runat="server">
<title></title>
<style type="text/css">
body {
background-image: url('Homee.png')

}
</style>
</head>
<body>
<form id="form1" runat="server">
<div>

</div>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
<p style="height: 47px; margin-top: 72px; width: 1445px;">
<asp:Button ID="Button1" runat="server" Text="Order now" Height="39px"
style="margin-left: 107px" Width="144px" onclick="Button1_Click" />
<asp:Button ID="Button4" runat="server" Text="Order Now" Height="39px"
style="margin-left: 187px" Width="141px" onclick="Button4_Click" />
<asp:Button ID="Button9" runat="server" Height="39px" onclick="Button9_Click"
style="margin-left: 188px" Text="Order Now" Width="144px" />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

Om Mishra (69)
TYIT B
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<asp:Button ID="Button10" runat="server" Height="39px" onclick="Button10_Click"
style="margin-left: 4px" Text="Order Now" Width="140px" />
</p>
<p align="left"
style="height: 103px; margin-top: 205px; width: 1479px; font-size: small;">
<asp:Button ID="Button8" runat="server" Height="43px" onclick="Button8_Click"
style="margin-left: 117px; margin-top: 52px" Text="Order Now" Width="140px" />
<asp:Button ID="Button7" runat="server" Height="39px"
style="margin-left: 194px; margin-top: 0px; margin-bottom: 4px" Text="Order Now"
Width="129px" onclick="Button7_Click" />
<asp:Button ID="Button6" runat="server" Height="39px"
style="margin-left: 196px" Text="Order Now" Width="120px"
onclick="Button6_Click" />
<asp:Button ID="Button3" runat="server" Text="Order Now" Height="39px"
style="margin-left: 238px" Width="140px" onclick="Button3_Click" />
</p>
</form>
</body>
</html>

Webform2.aspx.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace book
{
public partial class WebForm2 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

protected void Button8_Click(object sender, EventArgs e)


{
Response.Redirect("WebForm3.aspx");
}

protected void Button1_Click(object sender, EventArgs e)


{
Response.Redirect("WebForm3.aspx");
}

protected void Button4_Click(object sender, EventArgs e)


{
Response.Redirect("WebForm3.aspx");
}

protected void Button7_Click(object sender, EventArgs e)


{
Response.Redirect("WebForm3.aspx");
}

Om Mishra (69)
TYIT B
protected void Button6_Click(object sender, EventArgs e)
{
Response.Redirect("WebForm3.aspx");
}

protected void Button3_Click(object sender, EventArgs e)


{
Response.Redirect("WebForm3.aspx");
}

protected void Button9_Click(object sender, EventArgs e)


{

Response.Redirect("WebForm3.aspx");
}

protected void Button10_Click(object sender, EventArgs e)


{

Response.Redirect("WebForm3.aspx");
}
}
}

Webform3.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm3.aspx.cs"
Inherits="book.WebForm3" %>

<!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 runat="server">
<title></title>
<style type="text/css">
body {
background-image: url('kkk.png');
height: 728px;
width: 448px;
margin-left: 538px;
}
.style1
{
font-size: xx-large;
}
.style2
{
font-size: medium;
}
.style3
{
color: #00CCFF;
}
.style5
{
font-size: x-large;
font-weight: 700;
}

Om Mishra (69)
TYIT B
</style>
</head>
<body>
<form id="form1" runat="server">
<div class="style1" style="font-weight: 700; color: #CCFFFF; height: 39px">

<span class="style3">Product Order Form</span><br />


<span class="style5">Please fill all the Detail<br />
<asp:Label ID="Label1" runat="server" Text="Full Name"></asp:Label>
:</span><br />
<span class="style2">
<asp:TextBox ID="TextBox1" runat="server" Width="305px" placeholder = "First
Name"></asp:TextBox>
<br />
<br />
<asp:TextBox ID="TextBox2" runat="server" style="margin-left: 0px"
Width="310px" placeholder="Last Name"></asp:TextBox>
<br />
</span><span class="style5">Email:<br />
<asp:TextBox ID="TextBox3" runat="server" Width="314px" TextMode="Email"
placeholder="[email protected]"></asp:TextBox>
<br />
Phone Number:<br />
<asp:TextBox ID="TextBox4" runat="server" Width="311px"
TextMode="Number">+91</asp:TextBox>
<br />
Shipping Address:<br />
<asp:TextBox ID="TextBox5" runat="server" Height="66px" Width="309px"
placeholder="Enter address" ></asp:TextBox>
<br />
<br />
<asp:TextBox ID="TextBox6" runat="server" placeholder="city"></asp:TextBox>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<asp:TextBox ID="TextBox7" runat="server" Width="175px" placeholder="Pin code"
TextMode="Number"></asp:TextBox>
<br />
<br />
<asp:DropDownList ID="DropDownList1" runat="server">
<asp:ListItem Value="Maharashtra">State</asp:ListItem>
<asp:ListItem Value="Utter pradesh"></asp:ListItem>
<asp:ListItem Value="Maharashtra"></asp:ListItem>
<asp:ListItem Value="Madhey Pradesh"></asp:ListItem>
<asp:ListItem Value="Tamilnadu"></asp:ListItem>
<asp:ListItem Value="Banglore"></asp:ListItem>
<asp:ListItem></asp:ListItem>
</asp:DropDownList>
<asp:DropDownList ID="DropDownList2" runat="server" Height="22px"
style="margin-left: 75px" Width="180px">
<asp:ListItem>Country</asp:ListItem>
<asp:ListItem Value="India"></asp:ListItem>
<asp:ListItem Value="Usa"></asp:ListItem>
<asp:ListItem Value="New york"></asp:ListItem>
<asp:ListItem></asp:ListItem>
</asp:DropDownList>
<br />
<br />
Modes of Payment:<br />
<asp:DropDownList ID="DropDownList3" runat="server">
<asp:ListItem Value="COD"></asp:ListItem>

Om Mishra (69)
TYIT B
<asp:ListItem Value="Credit Card"></asp:ListItem>
<asp:ListItem Value="Debit Card"></asp:ListItem>
<asp:ListItem Value="UPI"></asp:ListItem>
<asp:ListItem></asp:ListItem>
</asp:DropDownList>
<br />
&nbsp;
<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<asp:Button ID="Button1" runat="server" onclick="Button1_Click"
style="background-color: #FFFF00" Text="Place Order" Width="191px" />
&nbsp;&nbsp;
<br />
</span>

</div>
</form>
</body>
</html>

Webform3.aspx.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace book
{
public partial class WebForm3 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

protected void Button1_Click(object sender, EventArgs e)


{
Response.Redirect("WebForm4.aspx");
}
}
}

Webform4.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm4.aspx.cs"
Inherits="book.WebForm4" %>

<!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 runat="server">
<title></title>
<style type="text/css">
body {
background-image: url('kkk.png');

Om Mishra (69)
TYIT B
}
.style1
{
font-size: x-large;
}
</style>
</head>
<body>
<form id="form1" runat="server">
<div style="height: 164px; width: 671px; font-size: xx-large; font-style: italic; font-weight: 700;
margin-left: 485px; margin-right: 271px; margin-top: 181px; background-color: #FF66FF">

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thank for Ordering to Page Turner<br />
&nbsp;&nbsp;&nbsp; <span class="style1">&nbsp;&nbsp;&nbsp;&nbsp; Your Product will be
Delivered in 2 to 4 day&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>

</div>
</form>
<p class="style1">
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</p>
<p>
&nbsp;</p>
<p>
&nbsp;</p>
</body>
</html>

Output:

Om Mishra (69)
TYIT B
Om Mishra (69)
TYIT B
Om Mishra (69)
TYIT B

You might also like