Hello !
How to read category and respective variable parameters in user defined .ini file?
file format
[Category1]
val1 10
val2 20
val3 str_id
[Category2]
val1 11
val2 15
cal3 name
plz help
with best regards,
sudsi
Printable View
Hello !
How to read category and respective variable parameters in user defined .ini file?
file format
[Category1]
val1 10
val2 20
val3 str_id
[Category2]
val1 11
val2 15
cal3 name
plz help
with best regards,
sudsi
Ini files are just text files, so the first thing you need to be reading about is
- fopen
- fgets
- fclose
Then you can add things like
- find Category
- find symbol
- find symbol in category
Or whatever else you want to do
For a properly formatted ini file on windows, you can also use the GetPrivateProfileString() and GetPrivateProfileInt() functions.
GetPrivateProfileString() and GetPrivateProfileInt()
which header are they in - is it windows.h ?
I bet Google would tell you if you asked nice enough.
Quzah.
google's not talking to me. I bugged it with so many questions yesterday
try the msdn.microsoft.com then ;)
GetPrivateProfileInt
GetPrivateProfileString
Don't understand why Google didn't work ... that took me more time to post than to find!
don't blame google for your mistakes :D