0% found this document useful (0 votes)
3 views3 pages

USER Registration Activity

This document outlines a laboratory exercise for creating a user registration form in Java. It includes steps for setting up a new project, designing the user interface, adding action listeners, and testing the functionality. The exercise emphasizes practical implementation using an IDE and Java components.

Uploaded by

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

USER Registration Activity

This document outlines a laboratory exercise for creating a user registration form in Java. It includes steps for setting up a new project, designing the user interface, adding action listeners, and testing the functionality. The exercise emphasizes practical implementation using an IDE and Java components.

Uploaded by

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

Name: Laboratory Exercise Date Performed: 05/09/24 Score:

_________________________________________ _______________________________

Section: Laboratory Exercise Title: Date Submitted: 05/09/24


User Registration Form _______________________________
_________________________________________

1. Create a New Java Project:

• Open your IDE and create a new Java project named "UserRegistrationForm".

2. Create a JFrame Form:

• Right-click on the project folder.

• Select "New" > "JFrame Form" (or similar depending on your IDE).

• Name the form "UserRegistrationForm".

3. Design User Interface (UI):

• Open the UserRegistrationForm.java file in your IDE.

• Design the UI for the user registration form:

• Create a JFrame for the main application window.

• Add JLabels for prompting user input (e.g., "Student ID:", "Name:", etc.).

• Add JTextFields for user input (for each field: student ID, name, phone number, department,
email address, address).

• Optionally, you can use JComboBox for selecting the department.

• Add a JButton for submitting the form.

• Arrange the components using layout managers (e.g., GridLayout, GridBagLayout, etc.)
for proper alignment.

4. Add Action Listeners:

• Implement the ActionListener interface in your class to handle button clicks.

• Add an action listener to the submit button.

• In the actionPerformed method, retrieve the values entered by the user from the text fields and
process them as needed (e.g., display in a dialog box).

5. Compile and Run:

• Compile your Java file.

• Run the program to see the user registration form in action.

• Test the functionality by entering values into the fields and clicking the submit button.
SAMPLE OUTPUT:
V. Screenshot of your output:

You might also like