Hi,
In my .cpp file, I declare some global variables of type QPixmap. When I run the app, it crashes when the app is starting (even before the constructor of the class is called).
Here is the code:
Note that I still not use these variables elsewhere, just declare them and the app is crashed when starting.Code:// Own #include "mainwindow.h" ... QPixmap defaultImage; //This causes runtime error QPixmap waitingImage; //This causes runtime error MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); .... }
Anyone can help???
Thanks.

Reply With Quote


.

