参考资料: https://www.cnblogs.com/huluwa508/p/10319568.html https://blog.csdn.net/qq_33475105/article/details/82192916 安装包: python_dotenv-0.10.3-py2.py3-none-any.whl PyQt5_sip-12.7.0-cp36-cp36m-win32.whl PyQt5-5.13.2-5.13.2-cp35.cp36.cp37.cp38-none-win32.whl pyqt5_tools-5.13.0.1.5-cp36-none-win32.whl Installation whl File Format: native (Windows64) PIP xxx.whl the install . 1 , may need to update PIP 2 , mounting Wheel, the install PIP Wheel; . 3 , this machine version is as follows: After installation check: PIP List to see if the following file: PyQt5 5.13 . 0 PyQt5 -sip 12.7 . 0 pyqt5 -tools 5.13 . 0.1 . 5 Python -dotenv 0.10 . 3 installation errors: 1 , suggesting that version does not match the native platform requirements, the need to re-download; 2 , there is a space on the command line ; according to the page arrangement reference: Setting -tools- External Tools: QtDesigner . 1, E: \ Python36- 32 \ Lib \ the sum of site Packages \ pyqt5_tools \ the Qt \ bin \ designer.exe 2 , $ $ FileDir pyuic . 1 , E: \ Python36- 32 \ python.exe 2 , -m PyQt5.uic.pyuic FileName $ $ - O $ FileNameWithoutExtension .py $ 3 , $ FileDir $ If an error occurs: from PyQt5 Import QtCore, QtGui, QtWidgets ModuleNotFoundError: No Module named ' PyQt5 ' modification: File -settings-Project interpreter- amended as python.exe directory (python3.6 installation directory, E: \ Python36- 32 \ python.exe right-click directly on the project or the menu bar "Tools", choose Tools External >>QtDesigner open QtDesigner, create a MainWindow, edit the following: then saved to the current project directory is selected hello.ui hello.ui, right, External Tools >> pyuic, generate hello.py. New main.py, add the following code: Import SYS Import Hello # Import UI from PyQt5.QtWidgets the QApplication Import, The QMainWindow IF the __name__ == ' __main__ ' : App = the QApplication (the sys.argv) UI = hello.Ui_MainWindow () mainWnd = The QMainWindow () ui.setupUi (mainWnd) mainWnd.show () sys.exit (app.exec_ ()) the OK!