Hi,
is there any way strip this
key=['5555','4444','5555']
to 555,4444,5555 ? When my program reads this settings from ini with using QSettings class it will procude a QStringList which has next items:
0 ['5555'
1 '4444'
2 '5555']
Printable View
Hi,
is there any way strip this
key=['5555','4444','5555']
to 555,4444,5555 ? When my program reads this settings from ini with using QSettings class it will procude a QStringList which has next items:
0 ['5555'
1 '4444'
2 '5555']
are you sure that is proper ini format?
you might have to put the value after '=' in double quotes and deal with the parsing of that string yourself.
key="['5555','4444','5555']"
or prevent the '[' and ']' to go into the ini file in the first place.
How do you read and write the settings file (provide some code)?
Assuming you can't get the INI file to be more what you would like to have, as schitzel suggested.
Iterate over the list, use QString::section(), separator character ' and section index 1.
Cheers,
_
ok,
I do have a project which transform a project from another language to Qt. Seems to that I have to format break in here.
thanks.