Bonjour,j ai un petit probleme d affichage d une photo dans une nouvelle fenetre. Pourriez vous m aider. Voici le code:
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15 def ketchup(): ketchup =Tk() ketchup.title("Ketchup") champ_label = Label(ketchup, text="Fiche info: Ketchup Heintz") champ_label.pack() ketchup.geometry("800x600") canvas = Canvas(ketchup,width=800, height=600) canvas.create_image(0, 0, anchor=NW, image=imgketchup) canvas.pack() Bouton1 = Button(fenetre, text = 'Ketchup', command = ketchup) Bouton1.pack()
La fenetre s affiche bien et la partie ecrite aussi mais la photo du ketchup ne s affiche pas j aimerais comprendre pourquoi. Merci Cordialement Diozone
Partager