I have a simple program that uses QSettings to load and store some information. I use the following code to init it:
I use something like this to store settings:
settingsFilePath = QDesktopServices::storageLocation(QDesktopServices::DataLocation);
settings = new QSettings(settingsFilePath + "/config", QSettings::IniFormat);
And something like this to load settings:
if(ui.cbnumOfNewsItems->currentIndex() == 5)
Now, here's my problem. Code works well in emulator on S60v5, S60v3fp1 and S60v3fp2. But when I build it for phones, it only works on S60v5. On S60v3 the settings file is created I think, because once you save something, it's saved while application is runing. But after the app is restarted it behaves as if no data was ever stored and you need to enter it again. Same story after that, data is loaded until app is restarted.
if(settings->value("NumOfNewsItemsShown").toInt() < 6)
Could someone tell me what could be causing problems?