我的代码显示AttributeError:我运行它时,“ PhotoImage”对象没有属性“ _PhotoImage__photo”

时间:2020-09-22 13:09:18

标签: python-3.x tkinter photoimage

from tkinter import *
from PIL import ImageTk, Image

my_image1 = ImageTk.PhotoImage(Image.open('melody1.png'))

my_image2 = ImageTk.PhotoImage(Image.open('melody.png'))

my_image3 = ImageTk.PhotoImage(Image.open('Erica.png'))

my_image4 = ImageTk.PhotoImage(Image.open('gaddiel.png'))

my_image5 = ImageTk.PhotoImage(Image.open('gaddiel1.png'))

0 个答案:

没有答案