Hello,
How can I modify this code that will work ? Because line 17 is not working..

Qt Code:
  1. Object::connect: No such slot qnicklist::invite(strInviteChannel) in qnicklist.cpp:146
To copy to clipboard, switch view to plain text mode 

Qt Code:
  1. ...
  2. void qnicklist::invite(QString strInviteChannel)
  3. {
  4. QString strNick = this->selectedItems().at(0)->text();
  5. qnicklist::send(QString("INVITE %1 %2").arg(strInviteChannel).arg(strNick));
  6. }
  7. ....
  8.  
  9. void qnicklist::contextMenuEvent(QContextMenuEvent *e)
  10. {
  11. ....
  12. QMenu *minvite = new QMenu("Invite");
  13. for (int i = 0; i < strOpenChannels.count(); i++)
  14. {
  15. QString strInviteChannel = strOpenChannels.at(i);
  16. if (strInviteChannel[0] == '#')
  17. minvite->addAction(strInviteChannel, this, SLOT(invite(strInviteChannel)));
  18. }
  19. ....
  20. }
To copy to clipboard, switch view to plain text mode