In QT5, when I use this: #include<QApplication>, QT tells :no such file or directory, even though it is all right for previous version of QT.

It turns out these files QApplication and so on have been moved to other places.

How to correct?

#include <QApplication> --------------------> #include <QWidgets/QApplication>

#include <QDialog> --------------------> #include <QWidgets/QDialog>

#include <QLabel> --------------------> #include <QWidgets/QLabel>

.....................blabla

when I do this, still there are some errors, I dunno...........

another way is to change the .pro file, make it adapt to qt4.

In QT gui, the application is necessary for a program, it is used for managing the program application resources.

QT5: QApplication, no such file or directory的更多相关文章

  1. QT5.1在Windows下 出现QApplication: No such file or directory 问题的解决办法

    QT5.0.1在Windows下 出现QApplication: No such file or directory 问题的解决办法 分类: 编程语言学习 软件使用 QT编程学习2013-03-07 ...

  2. QT5.0.1在Windows下 出现QApplication: No such file or directory 问题的解决办法

    第一个Qt 程序 环境window ,ide qt creator 新建一个 C++ 项目 > 新建一个main.cpp 输入如下代码 #include<QApplication> ...

  3. error: QApplication: No such file or directory

    尝试用Qt5编译Qt4的工程.你会遇到下面的问题: 错误:C1083: 无法打开包括文件:“QApplication”: No such file or directory 出现原因:Qt5里不再用Q ...

  4. <QT障碍之路>QApplication:No such file or directory

    原因:QT5将很多部件都移动了QT widgets模块中. 解决方法: 在.pro文件中添加 greaterThan(QT_MAJOR_VERSION, ): QT += widgets

  5. Qt 5 在Windows下 出现QApplication: No such file or directory 问题的解决办法

    解决方法是:在*.pro工程项目文件中添加一行QT += widgets,然后再编译运行就OK了.

  6. Qt5编译项目出现GL/gl.h:No such file or directory错误

    编译在Ubuntu12.04下安装了Qt5.1.1,在编译工程的时候出现了如下错误:“GL/gl.h:No such file or directory”,查了一下资料发现这个问题由于系统中没有安装O ...

  7. Visual Studio 2017 无法打开包括文件: “QOpenGLWidget”: No such file or directory

    编译项目时,发现报错:VS 无法打开包括文件: “QOpenGLWidget”: No such file or directory,在Qt对应的目录(E:\Qt\Qt5.12.2\5.12.2\ms ...

  8. qt下qmake:提示could not exec '/usr/lib/x86_64-linux-gnu/qt4/bin/qmake': No such file or directory

    编译出现的问题解决方法: 打开终端输入,qmake -v,出现错误:qmake: could not exec '/usr/lib/x86_64-linux-gnu/qt4/bin/qmake': N ...

  9. Arm Qt编译Qt例程出错 GLES3/gl3.h: No such file or directory 解决方法

    工作环境 PC:Ubuntu18.04QtCreator: 4.8.2交叉编译环境:野火imxull6开发板提供的 5-编译工具链->qt交叉编译工具 在之前博客配置成功的交叉编译环境,编译Qt ...

随机推荐

  1. Wpf Binding.Path设置

    Binding.Path 获取或设置绑定源属性的路径. 每个绑定通常都具有四个组件:绑定目标对象.目标属性.绑定源,以及要使用的绑定源值的路径.有关这些数据绑定概念的更多信息,请参见数据绑定概述. 使 ...

  2. 报错:ORA-02287: 此处不允许序号

    CREATE TABLE MY_TAB (N1 NUMBER(5),N2 DATE);          SELECT  * FROM MY_TAB;          CREATE SEQUENCE ...

  3. 使用ol,添加图书销售排行榜

    如果想在网页中展示有前后顺序的信息列表,怎么办呢?如,当当网上的书籍热卖排行榜,如下图所示. 这类信息展示就可以使用<ol>标签来制作有序列表来展示. 语法: <ol> < ...

  4. ASP.NET菜鸟之路之实现新闻列表增删改

    背景 我是一个ASP.NET菜鸟,暂时开始学习ASP.NET,在此记录下我个人敲的代码,没有多少参考价值,请看到的盆友们为我点个赞支持我一下,多谢了. 网站介绍 根据视频的例子修改的方法,其中数据不经 ...

  5. [个人原创]关于java中对象排序的一些探讨(三)

    这篇文章由十八子将原创,转载请注明,并标明博客地址:http://www.cnblogs.com/shibazijiang/ 对对象排序也可以使用Guava中的Ordering类. 构造Orderin ...

  6. 4.HTTP入门

    什么是http协议查看http协议的工具http协议内容Http请求请求行http协议版本请求资源请求方式GET方式提交POST方式提交请求头3.3 实体内容3.4 HttpServletReques ...

  7. 模拟vector

    实现了vector的模板,insert, erase, push_back, iterator #include<iostream> #include<string.h> #i ...

  8. 【COGS1049】天空中的繁星

    [题目背景] 第二届『Citric』杯NOIP提高组模拟赛 第二题 [题目描述] Lemon最近买了一台数码相机.某天Lemon很无聊,于是对着夜空拍了一张照片,然后把照片导入了电脑.Lemon想依靠 ...

  9. ES5严格模式

    http://www.cnblogs.com/snandy/p/3428171.html 介绍了由ECMA262规范定义的Javascript标准,旨在改善错误检查功能并且标识不会延续到未来js版本的 ...

  10. Java学习----变量是什么

    1.变量必须拥有的类型 2.变量必须拥有的名字 变量:具备名字和类型的可以存放类型匹配的数据的量 public class Student { public static void main(Stri ...