Try this:
#include <QApplication>
#include <QMainWindow>
#include "ui_test.h"
int main(int argc, char *argv[]){
Ui::Test ui;
ui.setupUi(window);
window->show();
return app.exec();
}
#include <QApplication>
#include <QMainWindow>
#include "ui_test.h"
int main(int argc, char *argv[]){
QApplication app(argc, argv);
QMainWindow *window = new QMainWindow();
Ui::Test ui;
ui.setupUi(window);
window->show();
return app.exec();
}
To copy to clipboard, switch view to plain text mode
but first check whether you have set the objectName property of your form to "Test".
Bookmarks