Jump to content

Python question


Derell

Recommended Posts

Hello all,

I'm new to the forum and the world of coding. I'm currently taking the beginners python 3 course. I'm on chapter 7 and I've just completed lesson 5 however I keep getting an error regarding the gif image that I saved from google. I'm certain the image is a gif file. Could there be something wrong with the image or the way it's been saved? I saved it to the desktop and a file folder. See the following error below and please advise. Thank you in advance.

Derell,

========== RESTART: C:/Users/Dell/Desktop/Lessons/12.20.20_practice.py =========
Traceback (most recent call last):
  File "C:/Users/Dell/Desktop/Lessons/12.20.20_practice.py", line 4, in <module>
    python_logo = PhotoImage(file="python.gif")
  File "C:\Users\Dell\AppData\Local\Programs\Python\Python39\lib\tkinter\__init__.py", line 4063, in __init__
    Image.__init__(self, 'photo', name, cnf, master, **kw)
  File "C:\Users\Dell\AppData\Local\Programs\Python\Python39\lib\tkinter\__init__.py", line 4008, in __init__
    self.tk.call(('image', 'create', imgtype, name,) + options)
_tkinter.TclError: couldn't open "python.gif": no such file or directory
>>> 

 

Link to comment
Share on other sites

  • 1 month later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...