private void btn_click_crypt(object sender, RoutedEventArgs e)
        {
            Fonctions fc = new Fonctions();

            //DB database = new DB();
            if (txt_clair.Text.Length > 0 && txt_clef.Text.Length > 0)
            {
                txt_chiffre.Text = fc.Crypt(txt_clair.Text, txt_clef.Text);
                //database.Clair = txt_clair.Text;
                //database.Clef = txt_clef.Text;
                //database.Crypte = txt_chiffre.Text;
                //database.Type = false;
                //fc.InsertDB(database);
            }
            else
            {
                if (txt_clair.Text.Length == 0)
                {
                    txt_clair_error.Text       = "Veuillez remplir le champ ci-dessus";
                    txt_clair_error.Visibility = Visibility;
                }
                if (txt_clef.Text.Length == 0)
                {
                    txt_chiffre_error.Text       = "Veuillez remplir le champ ci-dessus";
                    txt_chiffre_error.Visibility = Visibility;
                }
            }
        }
        public Accueil()
        {
            this.InitializeComponent();
            Fonctions fc = new Fonctions();

            fc.CreateTable();
        }
 private void btn_click_crypt(object sender, RoutedEventArgs e)
 {
     Fonctions fc = new Fonctions();
     //DB database = new DB();
     if (txt_clair.Text.Length > 0 && txt_clef.Text.Length > 0)
     {
         txt_chiffre.Text = fc.Crypt(txt_clair.Text, txt_clef.Text);
         //database.Clair = txt_clair.Text;
         //database.Clef = txt_clef.Text;
         //database.Crypte = txt_chiffre.Text;
         //database.Type = false;
         //fc.InsertDB(database);
     }
     else
     {
         if (txt_clair.Text.Length == 0)
         {
             txt_clair_error.Text = "Veuillez remplir le champ ci-dessus";
             txt_clair_error.Visibility = Visibility;
         }
         if (txt_clef.Text.Length == 0)
         {
             txt_chiffre_error.Text = "Veuillez remplir le champ ci-dessus";
             txt_chiffre_error.Visibility = Visibility;
         }
     }
 }
 public Accueil()
 {
     this.InitializeComponent();
     Fonctions fc = new Fonctions();
     fc.CreateTable();
 }