tofighi
16th July 2011, 04:42
I'm creating an application which should have Options form (dialog) and in this form I want to save some parameters such as some folder path, some configuration numbers,etc.
I want after saving the setting in the Options dialog, it saves it in the QSettings object and I'll be able to reload it when I need it.
How can I do this? and because these settings are important to all of other dialogs, I want to know the most efficient way to save these settings and also load it easily and also it will be accessible to all dialogs.
For example I have three forms:
MainWindow
Options
SomeDialog
folderPath1 = "c:/windows";
folderPath2 = "d:/programs";
size = 100;
I want to load Settings (folderPath1 , folderPath2 , size) in the start of program using MainWindow. Then I would like to be able to edit these settings via Options dialog.
In every point of program I would like to have access to these settings from SomeDialog.
Thanks in advance.
I want after saving the setting in the Options dialog, it saves it in the QSettings object and I'll be able to reload it when I need it.
How can I do this? and because these settings are important to all of other dialogs, I want to know the most efficient way to save these settings and also load it easily and also it will be accessible to all dialogs.
For example I have three forms:
MainWindow
Options
SomeDialog
folderPath1 = "c:/windows";
folderPath2 = "d:/programs";
size = 100;
I want to load Settings (folderPath1 , folderPath2 , size) in the start of program using MainWindow. Then I would like to be able to edit these settings via Options dialog.
In every point of program I would like to have access to these settings from SomeDialog.
Thanks in advance.