Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Getting compiliation error



  • #include "ui_file.h"

    class myWidget : public QDialog
    {
    Q_OBJECT

    public:
    
    myWidget(QWidget* parent);
    void mCreateContent();
    bool finalize();
    
    
    public slots:
    
    void slotProjectPathChanged(const QString& text);
    void slotFPGACBToggled(bool checked);
    void slotFPGABrowseButton(bool checked);
    void slotCBFPGAVendorActivated(int index);
    
    protected:
    
    void hideEvent(QHideEvent *event);
    

    signals:
    void updateNextButtonState(bool);

    private:
    
    Ui::up* _uiPtr;
    

    };

    #include "ui_file.h"

    class myWidget : public QDialog
    {
    Q_OBJECT

    public:
    
    myWidget(QWidget* parent);
    void mCreateContent();
    bool finalize();
    
    
    public slots:
    
    void slotProjectPathChanged(const QString& text);
    void slotFPGACBToggled(bool checked);
    void slotFPGABrowseButton(bool checked);
    void slotCBFPGAVendorActivated(int index);
    
    protected:
    
    void hideEvent(QHideEvent *event);
    

    signals:
    void updateNextButtonState(bool);

    private:
    
    Ui::up* _uiPtr;
    

    };
    error: 'signals' does not name a type
    signals:
    ^
    I dont know wny



  • @Qt-Enthusiast
    Depending on just what you have included prior to the error, verify:

    Note that other libraries that define variables called signals or slots may cause compiler warnings and errors when compiled alongside a Qt-based application. To solve this problem, #undef the offending preprocessor symbol.


Log in to reply