tkinter.TclError: image “pyimage3” doesn't exist

后端 未结 4 464
陌清茗
陌清茗 2020-11-27 06:41

I\'m having trouble with a function that shows an image for two seconds on screen, and then is destroyed. When the program runs the functions initial call procedurely works

4条回答
  •  悲哀的现实
    2020-11-27 07:04

    Maybe not for this exact case, but for a similar one, I found that the customary

    if __name__ == '__main__':
        wlcm_scrn()  #Call through procedure.
    

    solves the problem as well. This seems to kill the active window and to create a new one each time you re-call the same module.

提交回复
热议问题