[SOLVED] Qt in VS2008 issue



  • I installed the plugin and everything seemed to work fine, however when I try to compile (I didn't add any code, it's just the base code that is automatically created), I get the errors:

    1>------ Build started: Project: QTCalc, Configuration: Debug Win32 ------
    1>Uic'ing mainwindow.ui...
    1>Compiling...
    1>moc_mainwindow.cpp
    1>d:\dsfiles\qtcalc\qtcalc\generatedfiles\debug../../mainwindow.h(16) : error C2039: 'MainWindowClass' : is not a member of 'Ui'
    1>d:\dsfiles\qtcalc\qtcalc\generatedfiles\debug../../mainwindow.h(16) : error C2146: syntax error : missing ';' before identifier 'ui'
    1>d:\dsfiles\qtcalc\qtcalc\generatedfiles\debug../../mainwindow.h(16) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>d:\dsfiles\qtcalc\qtcalc\generatedfiles\debug../../mainwindow.h(16) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>mainwindow.cpp
    1>d:\dsfiles\qtcalc\qtcalc\mainwindow.h(16) : error C2039: 'MainWindowClass' : is not a member of 'Ui'
    1>d:\dsfiles\qtcalc\qtcalc\mainwindow.h(16) : error C2146: syntax error : missing ';' before identifier 'ui'
    1>d:\dsfiles\qtcalc\qtcalc\mainwindow.h(16) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>d:\dsfiles\qtcalc\qtcalc\mainwindow.h(16) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>.\mainwindow.cpp(6) : error C2065: 'ui' : undeclared identifier
    1>.\mainwindow.cpp(6) : error C2228: left of '.setupUi' must have class/struct/union
    1> type is ''unknown-type''
    1>main.cpp
    1>d:\dsfiles\qtcalc\qtcalc\mainwindow.h(16) : error C2039: 'MainWindowClass' : is not a member of 'Ui'
    1>d:\dsfiles\qtcalc\qtcalc\mainwindow.h(16) : error C2146: syntax error : missing ';' before identifier 'ui'
    1>d:\dsfiles\qtcalc\qtcalc\mainwindow.h(16) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>d:\dsfiles\qtcalc\qtcalc\mainwindow.h(16) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>Generating Code...
    1>Build log was saved at "file://D:\DSFiles\QTCalc\Win32\Debug\BuildLog.htm"
    1>QTCalc - 14 error(s), 0 warning(s)

    There is no reason why this should error out, it's just the default generated code...

    thanks

    EDIT: Fixed the issue, turns out the objectName was generated incorrectly somehow.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.