[Qt-interest] Passing arguments to SLOT()

Donal O'Connor donaloconnor at gmail.com
Mon Jul 5 12:05:06 CEST 2010


Just pass paramters like you do normally to any function. Slots can have
arguments just like functions, but if you have your own type I think you
have to register it with the Moc.

Donal

On Mon, Jul 5, 2010 at 11:54 AM, Nishant Sharma <nishant.031 at gmail.com>wrote:

> Hi,
> I have a function in which I have a QString; say, QString abc = "QT"
> Now, in this function, I have a connect() statement.
> In the SLOT function, that I call, I want to pass the variable, abc.
> How do I achieve the same?
>
> --
> Best Regards,
> Nishant Sharma
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20100705/a82c2a6d/attachment.html 


More information about the Qt-interest-old mailing list