c++ - Qt 5 build error: extra characters after test expression -


I'm trying to learn QT 5.3, and this is my first program (Hello World).

I do not understand why this error occurs. I have taken some simple code from the Internet to check whether I have installed QT correctly or not. Here's the code:

  #include & lt; QApplication & gt; # Include & lt; QPushButton & gt; Int main (int argc, char ** argv) {QApplication app (argc, argv); QPushButton Button ("Hello World!"); Button.show (); Return app.exec (); }  

The error is displayed in row 3, 5, 6, 8. I'm totally new to Qt, so please give a simple explanation.

Check the .pro file. Sometimes this happens because you do not have a blackslash at the end of a line that is not the last:

  HEADERS + = Qt / mainwindow.h \ Qt / MPrintableWidget.h \ Qt / Ampantable WidgetGram.H #OUoff \ "QT / MFICXDialog H \ QT / MSCPPH H \ / Code> 

Exclude every line given below, and need to end in a backslash.

< / Div>

Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -