Skip to content

Added a simple Task manager with basic GUI #2689

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 19, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions Todo_GUi.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
from tkinter import messagebox
import tkinter as tk

# Function to be called when button is clicked
def add_Button():
task=Input.get()
if task:
List.insert(tk.END,task)
Input.delete(0,tk.END)



def del_Button():
try:
task=List.curselection()[0]
List.delete(task)
except IndexError:
messagebox.showwarning("Selection Error", "Please select a task to delete.")



# Create the main window
window = tk.Tk()
window.title("Task Manager")
window.geometry("500x500")
window.resizable(False,False)
window.config(bg="light grey")

# text filed
Input=tk.Entry(window,width=50)
Input.grid(row=0,column=0,padx=20,pady=60)
Input.focus()

# Create the button
add =tk.Button(window, text="ADD TASK", height=2, width=9, command=add_Button)
add.grid(row=0, column=1, padx=20, pady=0)

delete=tk.Button(window,text="DELETE TASK", height=2,width=10,command=del_Button)
delete.grid(row=1,column=1)

# creating list box
List=tk.Listbox(window,width=50,height=20)
List.grid(row=1,column=0)




window.mainloop()
Loading