I have a problem with tk.Entry(...)
. I have to create a GUI (a window) where I have two inputs, lets call them A and B. I want to enter only numbers, as said before via Entry. I have also a Label C where I have to put the result of an algebraic equation, with A and B as variables, via button or instantaneously. Here's the problem I cannot figure out how to make Entry.get()
method work! Can someone write it for me?
I thought something like this:
A = tk.Entry(self)
A.pack
B = tk.Entry(self)
B.pack
C=tk.Label(self,text=str(int(A.get())+int(B.get()))
C.pack