CSC Project On Expense Tracker Application
CSC Project On Expense Tracker Application
First and foremost, I would like to thank my teacher, Mrs Sunantha, for their
invaluable guidance, support, and constructive feedback throughout this project.
Their expertise, patience, and encouragement were instrumental in shaping this
project and overcoming various challenges. The insightful discussions and thorough
evaluations provided by Mrs Sunantha significantly contributed to the depth and
quality of this work.
I am also profoundly grateful to Zion International Public School for providing the
necessary resources and a conducive environment for carrying out this project. The
support from the faculty and access to the institution's facilities significantly
contributed to the project's successful completion.
Lastly, I would like to thank my family and friends, who provided unwavering
support and motivation during the project. Their patience and understanding were
vital in allowing me to dedicate the necessary time and effort to this endeavor.
This project would not have been possible without the collective efforts and support
of all these individuals. I am truly grateful for their contributions and encouragement.
ABSTRACT
The application supports budget setting, enabling users to establish spending limits
and receive notifications when approaching their budget thresholds. Additionally,
users can generate visual reports and charts to visualize their financial data,
promoting informed decision-making and better financial discipline. Key
functionalities include tracking recurring expenses, generating monthly summaries,
and accessing historical data for comparative analysis.
By empowering users with the tools to manage their finances effectively, the Expense
Tracker application aims to enhance financial literacy and promote responsible
spending habits. Whether for students, families, or professionals, this application
serves as an essential resource for anyone looking to achieve their financial goals and
improve their overall financial well-being. Through intuitive design and robust
functionality, the Expense Tracker is poised to become an indispensable companion
in the journey toward financial stability
REQUIREMENT ANALYSIS
1. Hardware Requirements
To run the Expense Tracker Application, the hardware requirements are minimal due
to its lightweight nature. Here are the basic hardware requirements:
Hardware Requirements
Minimum Requirements: Recommended Requirements:
Processor: Dual-core processor (e.g., Processor: Quad-core processor (e.g.,
Intel i3 or equivalent) Intel i5 or equivalent)
RAM: 4 GB RAM RAM: 8 GB RAM or higher
Storage: 500 MB of available disk space Storage: 1 GB or more of available disk
space
Display: 1366 x 768 resolution Display: 1920 x 1080 resolution or
higher
Internet Connection: Required for cloud- Internet Connection: High-speed
based features internet for optimal performance
2. Software Requirements
Operating System:
Windows: Windows 10 or later
macOS: macOS Mojave or later
Linux: Ubuntu 18.04 or later
APPLICATION
The expense tracker application serves as a valuable tool for individuals looking to
take control of their finances. By providing features that facilitate the monitoring of
income and expenditures, the application empowers users to make informed financial
decisions. Below are the key applications of the expense tracker:
1. Financial Management:
The application facilitates real-time monitoring of both income and expenses,
allowing users to keep track of their financial activities seamlessly. This ongoing
visibility helps users stay aware of their financial situation, enabling them to make
timely adjustments as needed.
2. Expense Tracking:
Users can easily record their daily expenses within the application. By categorizing
these expenses—such as groceries, transportation, and entertainment—individuals
can gain a clearer understanding of where their money is going. This organized
approach simplifies financial analysis and planning.
3. Budgeting:
The application allows users to set budgets for various spending categories, helping
them to allocate funds wisely. By establishing spending limits, users can avoid
overspending and ensure that they remain within their financial means. This feature
promotes disciplined financial behavior.
7. User-Friendly Interface:
Designed with the user in mind, the application features an intuitive interface that
simplifies navigation and enhances the overall user experience. This ease of use
ensures that individuals of all backgrounds can effectively utilize the application
without technical difficulties.
8. Data Security:
A user starts their day by recording all their expenses, including coffee, lunch, and transportation.
By categorizing each entry (e.g., "Food," "Transport"), they can easily see where their money is
going at the end of the week, helping them identify spending habits.
Monthly Budgeting:
At the beginning of the month, a user sets a budget for various categories, such as
groceries ($300), entertainment ($150), and savings ($200). Throughout the month,
the application tracks their spending against these budgets, sending alerts if they
approach their limits, which helps them stay financially disciplined.
A user wants to save for a vacation in six months. They set a savings goal of $1,200
within the app. The application calculates that they need to save $200 each month and
tracks their progress, encouraging them to adjust their spending habits to reach their
goal by the target date.
ii) EXPLANATION
User Interface:
The front-end component of the application where users interact with various
features. It is designed for accessibility on both web and mobile platforms, ensuring a
seamless user experience across devices.
Expense Input:
This section is dedicated to the functionality that allows users to easily add and track
their daily expenses. Users can input amounts, descriptions, and dates, facilitating
accurate and timely expense management.
Expense Categories:
This feature categorizes expenses into predefined groups, such as Food, Transport,
and Entertainment. By organizing expenses, users can gain better insights into their
spending habits and make informed financial decisions.
Budgeting Module:
The budgeting module enables users to set financial limits for different categories,
helping them manage their spending effectively. Users can monitor their budget
adherence in real-time, promoting responsible financial behavior.
This component generates visualizations and detailed reports that help users
understand their spending patterns over time. By analyzing this data, users can
identify trends and areas where they can improve their financial habits.
Notifications & Alerts:
The application sends timely reminders for upcoming bills and alerts when users are
approaching their budget limits. These notifications encourage users to stay on track
with their financial commitments and avoid overspending.
Database Layer:
The backend system that securely stores all user data, including expenses, budgets,
and user settings. This layer ensures data integrity and enables efficient retrieval and
storage of information.
Security Module:
This module implements robust security measures to protect user data and ensure
privacy. It includes features like encryption and secure authentication to safeguard
sensitive financial information.
ALGORITHM
1. Initialize Application
• Start the application and display the main menu.
2. User Authentication
• Prompt user for login credentials.
• If credentials are valid, proceed to the dashboard.
• If not, prompt to re-enter or create a new account.
4. Add Expense
• Prompt user for the amount, category, and description.
• Store the expense in the database.
• Update the total expenses and display a confirmation message.
5. View Expenses
• Retrieve all recorded expenses from the database.
• Display expenses categorized by date and type.
• Allow the user to filter by category or date range.
6. Set Budget
• Prompt user to set budgets for different categories.
• Store the budget limits in the database.
• Display a confirmation of the set budgets.
7. View Reports
• Generate visual reports (e.g., pie charts, bar graphs) of spending habits.
• Display trends over time and comparisons against budget limits.
8. Manage Categories
• Allow users to add, edit, or delete expense categories.
• Update the categories in the database.
FUNCTION DEFINITIONS
• AddExpense():
• INPUT amount, category, description
• STORE expense in the database
• UPDATE total expenses
• RETURN confirmation message
• ViewExpenses():
• RETRIEVE expenses from the database
• DISPLAY expenses
• SetBudget():
• INPUT budget limits for categories
• STORE budget in the database
• RETURN confirmation message
• ViewReports():
• GENERATE reports based on expenses
• DISPLAY visualizations
• ManageCategories():
• INPUT category actions (add/edit/delete)
• UPDATE categories in the database
• SetSavingsGoals():
• INPUT goal amount and deadline
• STORE goal in the database
• TRACK progress
import datetime
import mysql
from tkcalendar import DateEntry
connector.commit()
# Functions
def list_all_expenses():
global connector, table
table.delete(*table.get_children())
if not table.selection():
mb.showerror('No expense selected', 'Please select an expense from the
table to view its details')
current_selected_expense = table.item(table.focus())
values = current_selected_expense['values']
def clear_fields():
global desc, payee, amnt, MoP, date, table
today_date = datetime.datetime.now().date()
def remove_expense():
if not table.selection():
mb.showerror('No record selected!', 'Please select a record to delete!')
return
current_selected_expense = table.item(table.focus())
values_selected = current_selected_expense['values']
surety = mb.askyesno('Are you sure?', f'Are you sure that you want to delete
the record of {values_selected[2]}')
if surety:
connector.execute('DELETE FROM ExpenseTracker WHERE ID=%d'
% values_selected[0])
connector.commit()
list_all_expenses()
mb.showinfo('Record deleted successfully!', 'The record you wanted to
delete has been deleted successfully')
def remove_all_expenses():
surety = mb.askyesno('Are you sure?', 'Are you sure that you want to delete all
the expense items from the database?', icon='warning')
if surety:
table.delete(*table.get_children())
clear_fields()
list_all_expenses()
mb.showinfo('All Expenses deleted', 'All the expenses were successfully
deleted')
else:
mb.showinfo('Ok then', 'The task was aborted and no expense was
deleted!')
def add_another_expense():
global date, payee, desc, amnt, MoP
global connector
clear_fields()
list_all_expenses()
mb.showinfo('Expense added', 'The expense whose details you just
entered has been added to the database')
def edit_expense():
global table
def edit_existing_expense():
global date, amnt, desc, payee, MoP
global connector, table
current_selected_expense = table.item(table.focus())
contents = current_selected_expense['values']
connector.execute('UPDATE ExpenseTracker SET Date = ?, Payee = ?,
Description = ?, Amount = ?, ModeOfPayment = ? WHERE ID = ?',
(date.get_date(), payee.get(), desc.get(), amnt.get(),
MoP.get(), contents[0]))
connector.commit()
clear_fields()
list_all_expenses()
mb.showinfo('Data edited', 'We have updated the data and stored in the
database as you wanted')
edit_btn.destroy()
return
if not table.selection():
mb.showerror('No expense selected!', 'You have not selected any
expense in the table for us to edit; please do that!')
return
view_expense_details()
def selected_expense_to_words():
global table
if not table.selection():
mb.showerror('No expense selected!', 'Please select an expense from the
table for us to read')
return
current_selected_expense = table.item(table.focus())
values = current_selected_expense['values']
def expense_to_words_before_adding():
global date, desc, amnt, payee, MoP
if not date or not desc or not amnt or not payee or not MoP:
mb.showerror('Incomplete data', 'The data is incomplete, meaning fill all
the fields first!')
if add_question:
add_another_expense()
else:
mb.showinfo('Ok', 'Please take your time to add this record')
# Frames
data_entry_frame = Frame(root, bg=dataentery_frame_bg)
data_entry_frame.place(x=0, y=30, relheight=0.95, relwidth=0.25)
tree_frame = Frame(root)
tree_frame.place(relx=0.25, rely=0.26, relwidth=0.75, relheight=0.74)
# Buttons' Frame
Button(buttons_frame, text='Delete Expense', font=btn_font, width=25,
bg=hlb_btn_bg, command=remove_expense).place(x=30, y=5)
# Treeview Frame
table = ttk.Treeview(tree_frame, selectmode=BROWSE, columns=('ID', 'Date',
'Payee', 'Description', 'Amount', 'Mode of Payment'))
table.config(yscrollcommand=Y_Scroller.set, xscrollcommand=X_Scroller.set)
list_all_expenses()
Advanced Analytics:
Incorporate machine learning algorithms to provide personalized insights and
predictions about spending habits and future expenses.
Multi-Currency Support:
Add the ability to handle multiple currencies, enabling users to track expenses while
traveling or using different currencies.
Collaboration Features:
Enable users to share their expenses with family or friends for joint budgeting or
shared expenses in group activities.
Customizable Reports:
Allow users to generate customized reports based on specific criteria, such as date
ranges or expense categories.
Investment Tracking:
Include features to track investments and savings accounts alongside regular
expenses for a comprehensive financial overview.
Mobile Wallet Integration:
Integrate with mobile wallet services to facilitate easy payments and automatic
expense tracking from transactions.
Gamification Elements:
Add gamification features, such as rewards for meeting budgeting goals, to encourage
user engagement and motivation.
These enhancements can significantly improve user experience and broaden the
functionality of the expense tracker application.
BIBLIOGRAPHY
Openai.com
NCERT textbooks
Class notes