1

I've seen a couple questions with the same error reported in them. Yet none of them seem to solve the problem.

When I run my code:

from Tkinter import *

master = Tk()

screen = Canvas(master, width = 200, height = 200)
screen.grid(row = 0, column = 0)

ammo = PhotoImage(file='ammo.gif')
screen.create_image(80,40 , image=ammo)

master.mainloop()

When i run it it gives me the error 'image "pyimage#" doesn't exist' (The # changes every time. Increasing by one each time you run the program)

When I put in the file path directly the image displays. But it cant seem to find the image when i have it in my Directory.

Help?

GuitarGaming
  • 13
  • 1
  • 5

0 Answers0