Results 1 to 3 of 3

Thread: error: forward declaration of 'struct QPushButton'

  1. #1
    Join Date
    Jan 2009
    Posts
    29
    Qt products
    Qt4
    Platforms
    Unix/X11

    Arrow error: forward declaration of 'struct QPushButton'

    OS: Ubuntu 8.10 x86.
    Qt version: 4.4.3

    Issue:

    Having a QDialogButtonBox object, when I am trying to do

    Qt Code:
    1. buttonBox->button(QDialogButtonBox::Ok)->setEnabled(false);
    To copy to clipboard, switch view to plain text mode 

    I get the error:

    dialog.cpp:39: error: invalid use of incomplete type 'struct QPushButton'
    /usr/include/qt4/QtGui/qdialog.h:49: error: forward declaration of 'struct QPushButton'

    Any ideas about how to fix this problem?

    Thanks.

  2. #2
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: error: forward declaration of 'struct QPushButton'

    Qt Code:
    1. #include <QPushButton>
    To copy to clipboard, switch view to plain text mode 
    J-P Nurmi

  3. #3
    Join Date
    Jan 2009
    Posts
    29
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: error: forward declaration of 'struct QPushButton'

    Thanks a lot.

Similar Threads

  1. Qpushbutton
    By iamhere in forum Qt Programming
    Replies: 5
    Last Post: 15th October 2008, 04:40
  2. Replies: 16
    Last Post: 23rd May 2008, 10:12
  3. problem with forward declaration
    By MarkoSan in forum General Programming
    Replies: 14
    Last Post: 6th January 2008, 21:45
  4. Make error with Qt Jambi 4.3.2_01
    By pamalite in forum Installation and Deployment
    Replies: 0
    Last Post: 22nd November 2007, 12:05

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.