[Qt-interest] QSetting Windows SystemScope Problem
Peter
qt at bienert-rh.de
Fri Jul 2 15:23:04 CEST 2010
Hi,
I have a problem with the removal of a key under HKLM/Software. I want
to check, if I can write in the HKLM/Software and if isWritable() ==
true, than I now, my rights are ok and I want to remove the new created key.
I did:
QSettings *obj4 = new QSettings(QSettings::NativeFormat,
QSettings::SystemScope,"MyTestRegKey");
obj4->setFallbacksEnabled(false);
if (obj4->isWritable())
{
QString name = obj4->fileName(); //shows the correct path
obj4->remove(name);
obj4->sync();
}
delete obj4;
First, the HKLM/Software/MyTestRegKey is created. This works...
But the remove does not work ! also obj4->clear() does not work.
Documentation does not show any help about the problem, examples show,
how to remove subkeys, but not how to delete the "MyTestRegKey"....
I need help please
Regards,
Peter
More information about the Qt-interest-old
mailing list