[SailfishDevel] Cannot access phone book on phone when starting app from QtCreator

Karsten Todtermuschke katomu at web.de
Mon Jan 6 00:23:45 UTC 2014

Hi Matze,

I observed the same issue.

I used QtContacts 5.0 in Qml and selected "org.nemomobile.contacts.sqlite" 
from the available managers for ContactModel.manager

In the output from the application started with QtCreator I read the error 
message: Unable to create contacts database directory 

so there is a double-slash in the path. I already found at the source of 

in file:


and method:

QSqlDatabase ContactsDatabase::open(const QString &databaseName)

how the path is created:

    QString privilegedDataDir(QString("%1/%2/")

I further found the defines in https://github.com/nemomobile/qtcontacts-sqlite/blob/master/src/engine/engine.pro where 


already includes the slash. So at this point I know why the double slash is in 
the path.

What I do not understand at all is: Why it works when I launch it at the 

Best regards,


Am Sonntag 05 Januar 2014, 23:10:46 schrieb Matthias Barmeier:
>I am unable to access the phone book when running my app from QtCreator
>on the phone.
>Is this a security feature ?
>Is it possible to work with a fake contact DB ?
>     Matze
>SailfishOS.org Devel mailing list

More information about the Devel mailing list