PDA

View Full Version : Undefined reference MyWidget::....()



DrDonut
7th March 2008, 15:47
Hi all,
I'm still quite new to QT (duuhh) but I encounterd a problem:
When I try to compile my program it gives:
undefined reference to MyWidget::newValue(int)
does annyone know why this is?
I attached my .cpp file to this post so you can see the code.

I also tried to put this connect stuff in the function leesin() (that's where the error is) in a different place, but it didn't work out because the objects are not defined in different functions.

Any help is appriciated
Thanx!

Extra info:
Version: QT 4.3.4
Platform: Windows XP

wysota
7th March 2008, 16:44
Did you rerun qmake after adding the signal to the class definition? If you did and it still doesn't work, clean your project and recompile it again. Especially make sure all moc_* files are deleted and recreated again during the compilation.