[Qt-interest] Runtime Error :- connect: No such slot ...

Andreas Pakulat apaku at gmx.de
Fri Feb 19 12:27:01 CET 2010


On 19.02.10 11:13:59, Wm. G. Urquhart wrote:
> Well needless to say I didn't find anything wrong when creating this 
> sample (is it that obvious?), so here it is.
> 
> This version uses a const QString & instead of an int but at runtime the 
> outcome is the same:
> 
> Object::connect: No such slot QPushButton::setText(const QString &) in 
> .\sigtest.cpp:9
> Object::connect:  (receiver name: 'pushButton')

If you look at the API docs you'll notice that setText is not a slot,
its a normal member function. Hence QObject::connect is correct.

Andreas

-- 
You're definitely on their list.  The question to ask next is what list it is.



More information about the Qt-interest-old mailing list