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

生也有涯,知也无涯。这篇文章主要讲述This application failed to start because no Qt platform plugin could be initialized相关的知识,希望能为你提供帮助。
错误提示
在打开PyQt5-tools中的Designer.exe时,提示如下错误:

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

文章图片

designer
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
解决方法
定位到python38Libsite-packagesPyQt5Qtplugins,这个位置取决于你安装Python的位置,我的电脑上该位置的完整路劲是:C:UsersfocksorAppDataLocalProgramsPythonPython38Libsite-packagesPyQt5Qtplugins
将该目录下的platforms文件夹复制到Python38Libsite-packagespyqt5_toolsQtin,并替换处于该目录下的platforms内的文件。
再次打开designer.exe,此时问题应该已解决。
参考
PyQt5 Designer is not working: This application failed to start because no Qt platform plugin could be initialized
提示
【This application failed to start because no Qt platform plugin could be initialized】如果你同样遇到该问题并通过此贴解决了问题,你可以留下你的评论来提示后来人该方法是可行的。

    推荐阅读