IDLE unable to find PyQt5 installation

巧了我就是萌 提交于 2021-02-05 06:52:01

问题


I'm trying to install and use PyQt5 on my Windows 10 computer. Actually, it's already installed but IDLE does not recognize the package.

I tried to import PyQt5 after I installed it but I got an import error. Then I tried something else:

pip install pyqt5

Here, I got a syntax error. Does anybody have an idea what's the problem? Thanks in advance.


回答1:


Installing Python 3.6.6 & PyQt5 on Windows (10)

Python3.6.6: Download & Install Python 3.6.6 https://www.python.org/downloads/windows/

PyQt5: From an elevated command prompt run:

  • python -m pip install --upgrade pip
  • pip install pyqt5
  • pip install pyqt5-tools
  • Add the pyqt5 environment variable to the system environment path like so:

Here is a youtube explaining the steps above



来源:https://stackoverflow.com/questions/54925099/idle-unable-to-find-pyqt5-installation

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!