Hi

I'm a newbie and am building an app that connect to a database. It all works fine when I use the following and use my own local file

QString homeLocation = QStandardPaths::locate(QStandardPaths::HomeLocatio n, QString(), QStandardPaths::LocateDirectory);
userFilePath = homeLocation+"DBDirectory";

However, I need to store the database within the application.

During development, I still need to be able to locate and access the database outside QTCreator so need to be able to locate it using file explorer for instance.

I can't seem to be able to do it

If I use the following, the directory gets created, but I can't locate it in my file system . . .

temppath=qApp->applicationDirPath()+"/DBDirectory";

QDir dir(temppath);
if (!dir.exists()) {
dir.mkpath(".");
qDebug() << "NOT FOUND";
}
else
{
qDebug() << "FOUND";
}

equally, if I use the following the directory gets created too, but again I can't locate it . . . .

temppath = "/DBDirectory";

I apologise in advance if this is a naive question.