CWinApp::GetProfileInt()一类的函数 或者 UINT GetPrivateProfileInt( LPCTSTR lpAppName, // section name LPCTSTR lpKeyName, // key name INT nDefault, // return value if key name not found LPCTSTR lpFileName // initialization file name ); 读取指定的配置文件,lpFileName是配置文件名
或者
UINT GetPrivateProfileInt(
LPCTSTR lpAppName, // section name
LPCTSTR lpKeyName, // key name
INT nDefault, // return value if key name not found
LPCTSTR lpFileName // initialization file name
);
读取指定的配置文件,lpFileName是配置文件名
LPCTSTR lpAppName, // 你定义的段
LPCTSTR lpKeyName, // 你的键名
LPCTSTR lpDefault, // 没有键值时的默认值
LPTSTR lpReturnedString, // char buff[xx]
DWORD nSize, // xxx
LPCTSTR lpFileName // 配置文件路径(完整路径)
);
WritePrivateProfileString:和上面的差不多,如果将 Private 去掉,可以不加路径(只写文件名),
函数自动到windows的默认路径搜索文件名