Esempio n. 1
0
 public static bool INIDeleteSection(string iniFile, string section)
 {
     if (string.IsNullOrEmpty(section))
     {
         throw new ArgumentException("The name of the node must be specified", "section");
     }
     return(IniHelper.WritePrivateProfileString(section, null, null, iniFile));
 }
Esempio n. 2
0
 public static bool INIWriteValue(string iniFile, string section, string key, string value)
 {
     if (string.IsNullOrEmpty(section))
     {
         throw new ArgumentException("The name of the node must be specified", "section");
     }
     if (string.IsNullOrEmpty(key))
     {
         throw new ArgumentException("The key must be specified", "key");
     }
     if (value == null)
     {
         throw new ArgumentException("The value can not be null", "value");
     }
     return(IniHelper.WritePrivateProfileString(section, key, value, iniFile));
 }