You are on page 1of 6

WORKSHEET 1.

1
Student Name: Chetan Sen UID: 20MCA1414
Branch: MCA Section/Group: 1B
Semester: 4th Date of Performance: 17-02-2022
Subject Name: WAD LAB Subject Code: 22E-20CAA-755

1. Aim/Overview of the practical:


To create WebUserControl and Custom Control.
2. Task to be done:
a) WAP to create two web user controls to create a header and footer for the web page
using existing controls.
b) WAP to create a custom control and add that control in toolbox.
3. Steps for experiment/practical:

For “A”
Step 1: Create Web Application
1. "Start" - "All Programs" - "Microsoft Visual Studio 2010".
2. "File" - "New Website" - "C#" - "Empty Website"
3. Provide the web site a name such as "CreatingUsercontrol" or another as you wish and specify the
location.
Step 2: Create the User Control
1. Then right-click on the project in the Solution Explorer then select "Add New Item" then select Web
User Control template.
2. Now click on Add then User Control will be added into the solution of the application. Now open the
design mode and add the two textboxes, one label, and one button.
3. Now write the code accordingly and run.

For “B”

Step 1: Create Custom Control


1. Right-click anywhere in the Toolbox window, selects Add Tab, and then provide a name
for the new tab.
2. Then, right-click anywhere inside the new tab, and then select Choose Items. The
Choose Toolbox Items dialog box will be displayed.
3. Select the custom controls from the available list, and then click OK.
4. Result/Output/Writing Summary:
For “A”
a) Create > New > Website

b) Select ASP.NET WEB APPLICATION


c) Add > New Item > Web user Control

d) Add your Code in SOURCE

e) Add your Design in DESIGN


f) Now run and see the result

For “B”
a) Toolbox > Right Click > Add Tab
b) Name your TAB > Right Click > Choose Item

c) Select Controls > Click OK


Learning outcomes (What I have learnt):
1. How to create a website program in Visual Studio 2010.
2. How to create a WebUserControl.
3. How to apply skin theme.
4. How to Create Custom Control.
5. How to add and customize Controls in Tool Box.

You might also like