That is my code
below. I used tkinter to calculate the limit of a function. I used Grid
geometry, but when I click the button Answer, but nothing comes out so I do not
know where I am doing wrong. I hope my code will be visible, I have tried to
fixer my email. Thank you!
from tkinter import*
from sympy import*
from sympy import
init_printing from
math import*
init_printing(use_unicode = True)
root = Tk()
#Create the
Limits Function
def
Limits():
x = symbols("x")
A = var1.get()
B = var2.get()
C=
limit(A,x,B)
text.insert(0.0,"str(C)")
p
#Create variable
var1 = StringVar()
var2 =IntVar()
var3 =IntVar()
var4 =IntVar()
var5 =StringVar()
Tops = Label(root, font =
("arial",10,"bold"),fg = "red",bg = "blue",text ="Limits").grid(row=0, column
=0 ,sticky = W)
#Create the Limts frame
Limits =Label(root,font =
("arial",10,"italic"),text = "Limite de:").grid(row = 2,column = 0, sticky = W)
Limits = Entry(root,text = var1).grid( row =
2,column = 1,sticky = W)
Limits = Label( root,font =
("arial",10,"italic"),text = "de x á ").grid(row = 2,column = 2)
Limits= Entry(root,text = var2).grid(row = 2,
column = 3)
Limits =Label(root,font =
("arial",10,"italic"),text = "á gauche(-) et droite(+)").grid(row = 2,column =
4,rowspan = 1,columnspan = 1 ,sticky = W)
Limits = Entry(root,text = var5).grid(row =
2,column = 5, sticky = W)
#Create a text on the right frame
text = Text(root).grid(row = 6, column = 2)
#Create the Button
Button1 = Button(Limits,font =
("arial",20,"bold"),fg = "red",bg = "blue", text = "Answer",command =
Limits).grid(row = 7, colu= 2)
_______________________________________________
Tutor maillist - [email protected]
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor