Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Easygui
#1
Hi. I need help with easygui. I am frighteningly New at coding. I don’t know how to fix the problem of the error message I receive.

>>> import easygui
>>> easygui.msgbox(“work”)
Error:
Traceback (most recent call last): File “<physhell#2>“, line 1, in <module> easygui.msgbox(“work”) AttributeError: ‘module’ object has no attribute ‘msgbox’
Please help.
Reply
#2
by any chance, do you have file named easygui.py in the current working directory?
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply
#3
I Have the file in the folder marked python 25. It’s root folder. And no I don’t understand it myself. I’m literally learning code from a book
Reply
#4
but it's a file you created, right?
Also note that python 2.5 is way outdated version of python. Latest python 2 version is 2.7.15.
And as you are new to programming you should start with python3. Python2 official support will end January 1st, 2020.
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply
#5
Yes. As per instructions on google

I will start with python 3 after going through the book. The syntax did not allow me to follow examples in python 3
Reply
#6
Your file should not be named easygui.py. You import your own file. Did you download and extract install easygui package?
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply
#7
I extracted it and copied the .py file into the python 25 file. I have tried installing it but with no success. Even tried doing it with command prompt like the internet said but it’s not letting me. I can import the easygui on the IDE but cannot use the functions it’s supposed to provide
Reply
#8
1. remove everything you have downloaded
2. use pip install --upgrade easygui. This will install it for python2. See the docs http://easygui.readthedocs.io/en/master/ - How to get easygui.
3. go to your working folder and create py file, e.g. myscript.py
4. Put your code in it and run it from terminal/command prompt with python myscript.py
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply
#9
Thanks. That’s the most info I’ve got all day. I will try it out and will then reply to this if it works or I I’m stuck. Thanks again

Does this mean that I can’t use IDLE anymore
Reply
#10
no problem to use IDLE. You can use python prompt or create/open and run a file from IDLE.
However note IDLE is considered very poor IDE
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Easygui [HELP] - How could I convert my enterbox into a multenterbox in python? C0D3R 5 2,265 Apr-05-2022, 04:15 AM
Last Post: deanhystad
  easygui use enter instead of ok udihamudi 2 1,971 Oct-04-2020, 01:45 PM
Last Post: deanhystad

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020