<div dir="ltr">Possibly because when you launch it from the SDK it runs either as a different user, or just isn't part of the session on the phone, ie. not all the environment variables are set, etc.<br></div><div class="gmail_extra">
<br clear="all"><div><div dir="ltr"><br>Timur<br><br></div></div>
<br><br><div class="gmail_quote">On Mon, Jan 6, 2014 at 1:23 AM, Karsten Todtermuschke <span dir="ltr"><<a href="mailto:katomu@web.de" target="_blank">katomu@web.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi Matze,<br>
<br>
I observed the same issue.<br>
<br>
I used QtContacts 5.0 in Qml and selected "org.nemomobile.contacts.sqlite"<br>
from the available managers for ContactModel.manager<br>
<br>
In the output from the application started with QtCreator I read the error<br>
message: Unable to create contacts database directory<br>
/home/nemo/.local/share/system//privileged/Contacts/qtcontacts-sqlite<br>
<br>
so there is a double-slash in the path. I already found at the source of<br>
qtcontacts-sqlite<br>
<br>
in file:<br>
<br>
<a href="https://github.com/nemomobile/qtcontacts-sqlite/blob/master/src/engine/contactsdatabase.cpp" target="_blank">https://github.com/nemomobile/qtcontacts-sqlite/blob/master/src/engine/contactsdatabase.cpp</a><br>
<br>
and method:<br>
<br>
QSqlDatabase ContactsDatabase::open(const QString &databaseName)<br>
<br>
how the path is created:<br>
<br>
    QString privilegedDataDir(QString("%1/%2/")<br>
            .arg(QString::fromLatin1(QTCONTACTS_SQLITE_CENTRAL_DATA_DIR))<br>
            .arg(QString::fromLatin1(QTCONTACTS_SQLITE_PRIVILEGED_DIR)));<br>
<br>
I further found the defines in <a href="https://github.com/nemomobile/qtcontacts-sqlite/blob/master/src/engine/engine.pro" target="_blank">https://github.com/nemomobile/qtcontacts-sqlite/blob/master/src/engine/engine.pro</a> where<br>

<br>
DEFINES +=<br>
'QTCONTACTS_SQLITE_CENTRAL_DATA_DIR=\'\"/home/nemo/.local/share/system/\"\''<br>
<br>
already includes the slash. So at this point I know why the double slash is in<br>
the path.<br>
<br>
What I do not understand at all is: Why it works when I launch it at the<br>
phone?<br>
<br>
Best regards,<br>
<br>
Karsten<br>
<br>
<br>
Am Sonntag 05 Januar 2014, 23:10:46 schrieb Matthias Barmeier:<br>
<div class="HOEnZb"><div class="h5">>Hi,<br>
><br>
>I am unable to access the phone book when running my app from QtCreator<br>
>on the phone.<br>
>Is this a security feature ?<br>
>Is it possible to work with a fake contact DB ?<br>
><br>
>Ciao<br>
>     Matze<br>
>_______________________________________________<br>
>SailfishOS.org Devel mailing list<br>
<br>
_______________________________________________<br>
SailfishOS.org Devel mailing list<br>
</div></div></blockquote></div><br></div>