public void Change(Profile profile)
        {
            ExchangeInfo   DBUser   = new ExchangeInfo();
            List <Profile> profiles = Get();
            Validation     valid    = new Validation(profile);

            for (int i = 0; i < profiles.Count; i++)
            {
                if (profiles[i].mail == profile.mail)
                {
                    if (valid.IsValidAccount())
                    {
                        entities.usersTables.Remove(DBUser.profileToDbUser(profiles[i]));
                        entities.usersTables.Add(DBUser.profileToDbUser(profile));
                        string path = System.IO.Directory.GetCurrentDirectory() + "\\ClientLog.txt";
                        using (StreamWriter writetext = new StreamWriter(path))
                        {
                            writetext.WriteLine("properties of " + profile.firstName + " has been changed");
                        }
                        break;
                    }
                }
            }
        }
        public void Add(Profile profile)
        {
            Validation valid = new Validation(profile);

            if (valid.IsValidAccount())
            {
                ExchangeInfo DBUser = new ExchangeInfo();
                usersTable   user   = DBUser.profileToDbUser(profile);
                entities.usersTables.Add(user);
                string path = System.IO.Directory.GetCurrentDirectory() + "\\ClientLog.txt";
                using (StreamWriter writetext = new StreamWriter(path))
                {
                    writetext.WriteLine("new user " + profile.firstName + " has been registered");
                }
            }
        }