ini文件读写类
函数说明:
SetFileName(CString NewFolderName,CString FileName)
设置要保存的文件夹NewFolderName和文件名FileName
SetFloat(CString Section, CString Item, float Value)
保存float型的Value到磁盘中去名字为Item
SetString(CString Section, CString Item, CString Value)
保存CString型的Value到磁盘中去名字为Item
SetInt(CString Section, CString Item, int Value)
保存CString型的Value到磁盘中去名字为Item
GetInt(CString Section, CString Item, int Value=0)
将变量Item的值读出来函数返回值为读到的Int型数据第三个参数使用默认值
GetFloat(CString Section, CString Item, float Value=0.0)
将变量Item的值读出来函数返回值为读到的Float型数据第三个参数使用默认值
GetString(CString Section, CString Item, CString Value="")
将变量Item的值读出来函数返回值为读到的String型数据第三个参数使用默认值
FileName |
以上函数的第一个参数Section随便赋值即可,在保存到磁盘中的文件中Section、Item和Value意义如下图:
Section |
Item |
Value |