Projet sujet 7
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

39 lines
638 B

#projet 7 interface graphique
import tkinter as tk
#Creation de la fenetre
fenetre =tk.Tk()
fenetre.title("Calcul d'IP")
canvas=tk.Canvas(width=500,height=500,bg="ivory")
canvas.grid()
label =tk.Label(fenetre, text="Hello World")
label.grid()
def recup():
message = value.get()
label.configure(text=message)
value = tk.StringVar()
value.set("Entrez votre adresse")
entree=tk.Entry(fenetre, textvariable=value, width=20)
entree.grid()
bouton =tk.Button(text="valider", command=recup)
bouton.grid()
fenetre.mainloop()