Ex. No.
1
CREATE AN EXPOSURE OF WEB APPLICATIONS AND TOOLS
Date :
Aim:
Create an exposure of web applications and tools.
Procedure:
1. Start Visual Studio, on the File menu select New, and then select Project.
2. In the New Project dialog box, select Visual C# as the programming language.
3. In the Templates pane, select [Link] Empty Web Application, and name the project.
4. Add the following [Link] controls to the Webform.
1. Label Box
2. Textbox
3. Radio button
4. List Box
5. Radio Buttons
6. Text Area
7. Button
PROPERTIES TABLE:
CONTROL PROPERTY VALUE
Label1 ID lbl1
Textbox1 ID txt1
RadioButton1 ID rdomale
List Box1 Text Male
Text Area1
Button1
Program:
Output:
Result :
Thus a feedback form is designed using Web Application and Tools.
Ex. No. 2
HTML CONTROLS
Date :
Aim:
Design a Form HTML CONTROLS in [Link] .
Procedure:
1. Start Visual Studio, on the File menu select New, and then select Project.
2. In the New Project dialog box, select Visual C# as the programming language.
3. In the Templates pane, select [Link] Empty Web Application, and name the project.
4. Add the HTML CONTROLS to the Webform.
Program:
<form method = "post">
<label for="name">Name:</label>
<input type="text" name="name"><br><br>
<label for="sex">Sex:</label>
<input type="radio" name="sex" id="male" value="male">
<label for="male">Male</label>
<input type="radio" name="sex" id="female" value="female">
<label for="female">Female</label> <br><br>
<label for="country">Country: </label>
<select name="country" id="country">
<option>Select an option</option>
<option value="nepal">Nepal</option>
<option value="usa">USA</option>
<option value="australia">Australia</option>
</select><br><br>
<label for="message">Message:</label><br>
<textarea name="message" id="message" cols="30" rows="4"></textarea><br><br>
<input type="checkbox" name="newsletter" id="newsletter">
<label for="newsletter">Subscribe?</label><br><br>
<input type="submit" value="Submit">
</form>
Output:
Result:
Thus a html form is designed using HTML CONTROLS
Ex. No. 3
HTML SERVER CONTROLS
Date :
Aim:
Create a Web Application using HTML SERVER CONTROLS.
Procedure:
1. Start Visual Studio, on the File menu select New, and then select Project.
2. In the New Project dialog box, select Visual C# as the programming language.
3. In the Templates pane, select [Link] Empty Web Application, and name the project.
4. Add the HTML CONTROLS to the Webform.
Program:
<%@ Page Language="C#" %>
<html>
<script runat="server">
void btnBookName_Click(Object Source, EventArgs E)
{
[Link] = [Link];
[Link] = 80;
}
</script>
<body>
<form runat=server>
<h1>HTML Server Controls</h1>
<br/>
<h2>The date and time is <% =[Link]( ) %>.</h2>
<br/>
<h2>HTML Server Control</h2>
Book Name:
<input type="text"
id="txtBookName"
size="40"
value="Enter book name."
runat="server" />
<br/> <br/> <br/>
<input type="submit"
id="btnBookName"
value="Book Name"
onServerClick="btnBookName_Click"
runat="server" />
<br/>
<br/>
<input type="text" id="lblBookName" size="40" runat="server" />
</form>
</body>
</html>
Ex. No. 4
WEB APPLICATION USING WEB CONTROLS.
Date :
Aim:
Web application using Web controls.
Procedure:
1. Start Visual Studio, on the File menu select New, and then select Project.
2. In the New Project dialog box, select Visual C# as the programming language.
3. In the Templates pane, select [Link] Empty Web Application, and name the project.
4. Add the Web controls to the Web form
Program:
using [Link];
using [Link];
using [Link];
namespace PalindromeCheck
public partial class PalindromeNumberCheck : [Link]
{ protected
void Page_Load(object sender, EventArgs e) { }
protected void btncheck_Click(object sender, EventArgs e)
{ int num = [Link]([Link]); int n, rev = 0, d;
n = num;
while (n > 0)
{ d = n % 10;
n = n / 10;
rev = rev * 10 + d;
if (rev == num)
[Link] = [Link] + num + " is a Palindrome number.";
else
[Link] = [Link] + num + " is not a Palindrome number.";
}}}
Output:
Result:
Thus, a Web application using Web controls is created.
Ex. No. 5
WEB APPLICATION USING LIST CONTROLS.
Date :
Aim:
To create a Web application using List controls.
Procedure:
1. Start Visual Studio, on the File menu select New, and then select Project.
2. In the New Project dialog box, select Visual C# as the programming language.
3. In the Templates pane, select [Link] Empty Web Application, and name the project.
4. Add the List controls to the Web form
using System;
namespace list
public partial class listselect : [Link]
protected void Page_Load(object sender, EventArgs e)
{
protected void btnAdd_Click(object sender, EventArgs e)
int i;
for (i = 0; i < [Link]; i++)
if ([Link][i].Selected == true) [Link] += [Link][i].Text + "\
n"; }
}}}
Output: