PDA

View Full Version : how to remove .ini file



rahulgogoi
6th June 2011, 14:00
hello friends

actually i have created an .ini file using QSettings in qt...now i have a button called reset..what i want to do is to remove the .ini file on click of reset button..but i dont understand how can i do it..i had QSetting remove() functions..but doesnt work...code i had written is..

QSettings settings;
QString strRegPathName("/SeeCycleApp-build-desktop/debug/Unknown Organization.ini");
settings.remove(strRegPathName);
CycleManager* pCycMan = new CycleManager();
pCycMan->onInitializationValue();
delete pCycMan;

dbzhang800
6th June 2011, 14:05
bool QFile::remove ( const QString & fileName ) [static]

rahulgogoi
6th June 2011, 14:27
can u please explain me how it can be done..

Added after 15 minutes:

Thanks dbzhang its done..