Exemple #1
0
        public void ReadDB()
        {
            XmlSerializer deserializer = new XmlSerializer(typeof(UsersDB));

            if (File.Exists(UsersXmlPath))
            {
                using (TextReader reader = new StreamReader(UsersXmlPath))
                {
                    UsersDB = (UsersDB) deserializer.Deserialize(reader);
                }
            }
            else
            {
                Debug.WriteLine("File missing");
            }
        }
Exemple #2
0
 public UserDBManager()
 {
     UsersXmlPath = @"..\..\..\Resources\UsersData\UsersData.xml";
     UsersDB = new UsersDB();
 }