AJP Introduction 2
AJP Introduction 2
Introduction to
“Event Reminder Application Micro Project”
The Event Reminder Application is an intuitive and interactive desktop tool built using Java
Swing, developed as an advanced Java micro project. This application enables users to create,
edit, and delete events while setting reminders and priorities to help users stay organized.
With a focus on usability, it provides a straightforward interface to manage tasks and track
important dates, incorporating essential features for maintaining and prioritizing events.
Key Components and Functionalities
1. Event Management: Users can add new events, providing details such as title,
description, date, time, and priority level (High, Medium, Low). Each event is stored
as an Event object with all necessary attributes, such as title, description, dateTime,
and priority.
2. Graphical User Interface (GUI): Built using Java Swing, the application offers a
user-friendly and visually organized interface. The JList component displays events,
with buttons for adding, editing, and deleting items located at the bottom for quick
access.
3. Interactive Event Form: A separate form appears to enter or modify event details. It
includes text areas for the title and description, fields for date and time, and a
dropdown menu for priority. The form’s layout ensures that users can easily read and
input event data.
4. Priority-Based Sorting and Display: Events can be prioritized, enabling users to set
the importance of each task. The priority levels assist in planning by distinguishing
tasks based on urgency.
Code Structure
• Event Class: Handles event data, including title, description, date and time, and
priority. The class includes getters, setters, and a toString method to display event
summaries in the list.
• EventReminderApp Class: Controls the application's main functionalities, including
initializing the GUI, managing the event list, and handling user actions (add, edit,
delete). The openEventForm method enables editing within a dedicated dialog box.
• Java Swing Components: Utilizes JFrame, JList, JTextArea, JTextField, and
JComboBox to create a dynamic interface, allowing users to interact with the
application seamlessly.
Technical Overview
This project exemplifies advanced Java concepts, including object-oriented programming,
GUI design, and data handling. It showcases an application of Java Swing for real-world
scenarios, providing a practical tool for personal organization and event tracking.
Page 1 of 10
Advanced Java Micro Project Event Reminder Application
Project Code:
Event.java Class Code:
package vansh;
import java.time.LocalDateTime;
@Override
public String toString() {
return title + " - " + dateTime.toString() + " (" + priority + ")";
}
}
Page 2 of 10
Advanced Java Micro Project Event Reminder Application
import javax.swing.*;
import java.awt.*;
import java.time.LocalDateTime;
import java.util.ArrayList;
// Event List
eventListModel = new DefaultListModel<>();
eventList = new JList<>(eventListModel);
eventList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
JScrollPane scrollPane = new JScrollPane(eventList);
// Buttons Panel
JPanel buttonPanel = new JPanel();
JButton addButton = new JButton("Add Event");
JButton editButton = new JButton("Edit Event");
JButton deleteButton = new JButton("Delete Event");
buttonPanel.add(addButton);
buttonPanel.add(editButton);
buttonPanel.add(deleteButton);
Page 3 of 10
Advanced Java Micro Project Event Reminder Application
frame.add(buttonPanel, BorderLayout.SOUTH);
frame.setVisible(true);
}
saveButton.addActionListener(e -> {
String title = titleArea.getText();
String description = descriptionArea.getText();
Page 4 of 10
Advanced Java Micro Project Event Reminder Application
if (eventToEdit != null) {
eventToEdit.setTitle(title);
eventToEdit.setDescription(description);
eventToEdit.setDateTime(dateTime);
eventToEdit.setPriority(priority);
eventList.repaint();
} else {
Event newEvent = new Event(title, description, dateTime, priority);
events.add(newEvent);
eventListModel.addElement(newEvent);
}
dialog.dispose();
});
inputPanel.add(new JLabel("Title:"));
inputPanel.add(titleArea);
inputPanel.add(new JLabel("Description:"));
inputPanel.add(descriptionArea);
inputPanel.add(new JLabel("Date (YYYY-MM-DD):"));
inputPanel.add(dateField);
inputPanel.add(new JLabel("Time (HH:MM):"));
inputPanel.add(timeField);
inputPanel.add(new JLabel("Priority:"));
inputPanel.add(priorityBox);
dialog.add(inputPanel, BorderLayout.CENTER);
dialog.add(saveButton, BorderLayout.SOUTH);
dialog.setVisible(true);
}
Page 5 of 10
Advanced Java Micro Project Event Reminder Application
Output:
Event Reminder
Create Event
Page 6 of 10
Advanced Java Micro Project Event Reminder Application
Creating Event
Event Created
Page 7 of 10
Advanced Java Micro Project Event Reminder Application
Edit Event
Event Edited
Page 8 of 10
Advanced Java Micro Project Event Reminder Application
Deleted Event
Page 9 of 10
Advanced Java Micro Project Event Reminder Application
Conclusion:
This micro project demonstrates the development of a basic Event Reminder
Application using advanced Java concepts and Java Swing for GUI. Through
this project, we have effectively implemented object-oriented programming,
event handling, and graphical interface design. The application allows users to
create, edit, and delete events with specific details, including title, description,
date, time, and priority.
Developing this project has provided practical insights into building interactive
desktop applications, especially focusing on user experience and data
management. We chose this application because event management is a
common task, and a simple tool like this can be useful for organizing personal
schedules. This project has enhanced our understanding of structuring Java
applications and utilizing Java Swing components to design functional and user-
friendly interfaces.
Reference:
• Corsera
• TutorialsPoint
• YouTube
Page 10 of 10