Exemplo n.º 1
0
        public static bool LoadXML(string URL)
        {
            bool          Result = false;
            XmlSerializer rd     = new XmlSerializer(typeof(XMLConfig.config));

            try
            {
                using (XmlReader reader = XmlReader.Create(URL))
                {
                    AppSetting     = (XMLConfig.config)rd.Deserialize(reader);
                    FileLoadedDate = System.IO.File.GetLastWriteTime(URL);
                    Result         = true;
                }
            }
            catch (Exception ex)
            {
                LogTools.Write(null, ex, "Config.LoadXML");
            }
            return(Result);
        }
Exemplo n.º 2
0
 public static XMLConfig.config Reload()
 {
     _AppSetting = null;
     return(AppSetting);
 }