Results 1 to 4 of 4

Thread: QT example GUI error

  1. #1
    Join Date
    Jun 2011
    Posts
    14
    Qt products
    Qt4
    Platforms
    Windows

    Default QT example GUI error

    Hi everyone..I just started using qt and am trying to create a GUI from the following link.
    http://sector.ynet.sk/qt4-tutorial/m...plication.html

    I copy paste all the files ,but when I run this program it shows the error "expected class-name before '{' token".
    Kindly help me out with this,
    Thankyou

  2. #2
    Join Date
    Mar 2011
    Location
    Hyderabad, India
    Posts
    1,882
    Thanks
    3
    Thanked 452 Times in 435 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows
    Wiki edits
    15

    Default Re: QT example GUI error

    This should be basic C / C++. Are you new to C++?

    The error means what it says, "expected class-name before '{' token"., the name before { is not known, may be you missed the include file?

  3. #3
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: QT example GUI error

    The copy and paste version, and complete zipped example ,from that site compiles just fine here. Perhaps your copy'n'paste skills are the problem here.

  4. #4
    Join Date
    Jun 2011
    Posts
    14
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: QT example GUI error

    Thanks..yes it was my silly mistake,it worked..
    Thanks to both of you

Similar Threads

  1. no compile error, but error on run with QMenu QAction
    By sincnarf in forum Qt Programming
    Replies: 4
    Last Post: 4th May 2011, 11:05
  2. : error: [\NokiaQtSDK\Symbian\SDK\epoc32\release\gcce\udeb\V ideo.exe] Error 1
    By ranjit.kadam in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 1st May 2011, 22:11
  3. Replies: 3
    Last Post: 23rd January 2011, 12:15
  4. fatal error C1001: An internal error has occurred in the compiler
    By noodles in forum Installation and Deployment
    Replies: 0
    Last Post: 12th August 2010, 11:24
  5. Replies: 1
    Last Post: 25th October 2008, 19:18

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.