Error writing to invalid argument
-
Hii iam getting the following error while building the just sample project. i found solutions like
i) shadow build
ii)create debug and release foler
iii) remove \ after the lat cpp or .h file in .protried all those but no result.
is there any solution for this? please help me -
Hii iam getting the following error while building the just sample project. i found solutions like
i) shadow build
ii)create debug and release foler
iii) remove \ after the lat cpp or .h file in .protried all those but no result.
is there any solution for this? please help me -
Fix your main.cpp - the compiler tells you where you made an error so fix it.
-
Then the error is in mainwindow.h and the compiler can only give a follow-up error because you miss a
)
in there. -
@Jyothi
Have a read of https://stackoverflow.com/questions/42873311/error-writing-to-invalid-argument to see if anything there is your situation. -
Hi,
this is my mainwindow.h file
#ifndef MAINWINDOW_H
#define MAINWINDOW_H#include <QMainWindow>
namespace Ui {
class MainWindow;
}class MainWindow : public QMainWindow
{
Q_OBJECTpublic:
explicit MainWindow(QWidget *parent = 0);
~MainWindow();private:
Ui::MainWindow *ui;
};#endif // MAINWINDOW_H
-
Hi,
this is my mainwindow.h file
#ifndef MAINWINDOW_H
#define MAINWINDOW_H#include <QMainWindow>
namespace Ui {
class MainWindow;
}class MainWindow : public QMainWindow
{
Q_OBJECTpublic:
explicit MainWindow(QWidget *parent = 0);
~MainWindow();private:
Ui::MainWindow *ui;
};#endif // MAINWINDOW_H
@Jyothi
I cannot see anything wrong there.I really expected something from that stackoverflow post I referred you to to be at issue, but you say not. You might want to paste your
.pro
file because of one of the tips there?Otherwise I can only suggest you start a fresh project in a fresh directory. Do not even define your own
MainWindow
. Start with just aQWidget
or aQMainWindow
. In fact, you could change your existing program to use aQMainWindow
instead ofMainWindow
, and#include <QMainWindow>
in place of#include "mainwindow.h"
. Does that work? Then build back up to what you have now.