View Full Version : Qdbus remote method calling issue

19th May 2011, 09:19
Hi ,

My remote method signature is

void SetProperty(string property, variant value)

Here i am calling my method with

QVariant v(1);

enable.enable(QString("Powered"),v); // calling

inline QDBusPendingReply<> enable(const QString &value,const QVariant &var)
QList<QVariant> argumentList;
argumentList << qVariantFromValue(value) << qVariantFromValue(var);
return asyncCallWithArgumentList("SetProperty", argumentList);

It giving error like

"Method "SetProperty" with signature "ss" on interface "xxx" doesn't exist

How do i send my second argument as variant

21st May 2011, 01:28
Are you sure you are calling the method on a proper object/interface? Can you call other methods successfully? Also, what does "var" contain? What if you change line #9 to:

argumentList << value << var;