Here is the Tk base window, which will receive data for the month, day, and year.
from Tkinter import * root = Tk() label1 = Label( root, text="Month(MM)") E1 = Entry(root, bd =5) label2 = Label( root, text="Day(DD)") E2 = Entry(root, bd =5) label3 = Label( root, text="Year(YYYY)") E3 = Entry(root, bd =5) def getDate(): print E1.get() print E2.get() print E3.get() submit = Button(root, text ="Submit", command = getDate) label1.pack() E1.pack() label2.pack() E2.pack() label3.pack() E3.pack() submit.pack(side =BOTTOM) root.mainloop()
when you click the send button, it prints the day and year of the month, and I'm sure you can understand it from there
EDIT
here is an example of a text box to display a diary entry:
from Tkinter import * root = Tk() text = Text(root) text.insert(INSERT, diary) text.pack() root.mainloop()
in this example, diary is the diary entry line!
Good luck :)
source share