库文件
System.Runtime.InteropServices
项目
录音系统V3.0(C/S)
代码
class IniFile
{
#region 运行变量定义
public string m_strPath; //INI文件名
#endregion
#region 构造函数及资源回收
public IniFile(string INIPath)
{
m_strPath = INIPath;
}
#endregion
#region API函数声明
//声明读写INI文件的API函数
[DllImport("kernel32")]
private static extern long WritePrivateProfileString(string
section, string key, string val, string filePath);
[DllImport("kernel32")]
private static extern int GetPrivateProfileString(string section, string key, string def, StringBuilder retVal, int size, string filePath);
#endregion
#region 共有函数处理