Note my earlier replyYou get an error because you don't know how to use signals & slots (Don't feel bad). I will try to explain a bit, you should be reading a good book or Qt Documentation at-least.Originally Posted by Santosh Reddy
Following points are what you missed
- main() is a global function, it does not have a object instance of itself, so you cannot use this pointer in main() (it's basic C++, nothing to do with Qt), this is very reason you have an error.
- A slot has to a member function of a class which is either directly or indirectly derived from a QObject, i.e SLOT cannot be a global function (which is a problem in you case)
- You are creating 27 (3 x 9) timers, you should be creating only one timer, and each time the timer slot is called then create a balloon.
Bookmarks