How pass QDBusObjectPath as argument in remote method call

Nirav Rabara Nirav.Rabara at Matrixtelesol.com
Thu Nov 26 04:29:39 PST 2009


Hi,

 

I am using Qt binding to call remote method, but following line of code give
error while compiling.( I have attached code with this mail)

 

QDBusConnection conn = QDBusConnection::systemBus();

int main(int argc, char **argv)

{

    QCoreApplication app(argc, argv);

    QDBusInterface interface("org.bluez", "/org/bluez/806/hci0",
"org.bluez.Adapter" , conn,0);

 

   qDebug() << "Isvalid - "<< interface.isValid();

 

   QDBusObjectPath removeDevPath;

 

   // Shows error here

   removeDevPath.setPath = ("/org/bluez/806/hci0/dev_00_1C_EF_44_D6_1D");

 

 

    interface.call("RemoveDevie", removeDevPath);

 

 

}

 

 

error: QString is an inaccessible base of 'QDBusObjectPath'.

 

Please can any body suggest me how to send QDBusObjectPath as argument in
remote method call.

 

Your suggestion would be a great help for me.

 

With Regards,

Nirav 

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freedesktop.org/archives/dbus/attachments/20091126/1490306f/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: main.cpp
Type: application/octet-stream
Size: 526 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/dbus/attachments/20091126/1490306f/attachment.obj 


More information about the dbus mailing list