ini files
-
I have a problem . When I want to create .INI file with some SECTIONs and I want to insert SPACE among them . Ex. : [Section1] data1 = ... data2 = ... <= there I want to create the SPACE [Section2] Best regards. Tomas
-
:confused: ?? huh? Does:
outfile << "data2 = " << data2 << "\n\n" << "[Section2]\n";
not work?? - Nitron
"Those that say a task is impossible shouldn't interrupt the ones who are doing it." - Chinese Proverb
-
this can be right, but I adding rows to the ini file by WritPrivateProfileString and I can`t make the SPACE !!! I tryied many ways to make the SPACE but I don`t be successful . thank you Tomas
I think you would need to flush the file after doing your WritePrivateProfileStrings(), and then go back and open it using something like a CStdioFile to write the blank lines. You could also do it with a binary file, I don't know which would be easier. The point is that WritePrivateProfileString does not have an option to do this as far as I know. I have been using this function for a long time, and have never seen a way to do this wihtout manually writing to the file. I could be wrong. It's happened many times before. Good luck.