This application failed to start because no Qt platform plugin could be initialized

错误提示

在打开PyQt5-tools中的Designer.exe时,提示如下错误:

image-20200619231239409

designer

This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

解决方法

定位到Python38\Lib\site-packages\PyQt5\Qt\plugins,这个位置取决于你安装Python的位置,我的电脑上该位置的完整路劲是:C:\Users\focksor\AppData\Local\Programs\Python\Python38\Lib\site-packages\PyQt5\Qt\plugins

将该目录下的platforms文件夹复制到Python38\Lib\site-packages\pyqt5_tools\Qt\bin,并替换处于该目录下的platforms内的文件。

再次打开designer.exe,此时问题应该已解决。

参考

PyQt5 Designer is not working: This application failed to start because no Qt platform plugin could be initialized

提示

如果你同样遇到该问题并通过此贴解决了问题,你可以留下你的评论来提示后来人该方法是可行的。

posted @ 2020-06-19 23:21  focksor  阅读(7953)  评论(4编辑  收藏  举报