Application failed to start because it could not find or load the QT platform plugin “windows”

用VS 2015进行QT程序开发时,在vs界面中调试编译程序时没有问题,但是进入到生成的exe文件夹下运行exe文件是却总是跳出一个提示框:

Application failed to start because it could not find or load the QT platform plugin “windows”;这几个字困扰我许多天,尝试过网上许多方法,都不能成功。当然,在我的不懈努力下还是解决了。

 

解决方法:1. 可以吧这个exe文件拷贝到qt的安装目录下的bin目录下运行即可,比如我的C:\Qt\Qt5.8.0\5.8\msvc2015\bin;

     2. 把bin目录下的Qt5Core.dll, Qt5Gui.dll, Qt5Widgets.dll以及C:\Qt\Qt5.8.0\5.8\msvc2015\plugins\platforms拷贝到exe同级目录。platforms文件夹下有qminimal.dll, qoffscreen.dll, qwindows.dll.

 

posted @ 2017-06-16 16:15  -DZY  阅读(26179)  评论(4编辑  收藏  举报