private void button1_MouseClick(object sender, MouseEventArgs e)
        {
            FicheSouhaitsViz fsv = new FicheSouhaitsViz();

            fsv.Show(this);
            this.Hide();
        }
Beispiel #2
0
        private void details_MouseClick(object sender, MouseEventArgs e)
        {
            ApplicationState.id_souhait = listView1.SelectedItems[0].SubItems[0].Text;
            FicheSouhaitsViz fsv = new FicheSouhaitsViz();

            fsv.Show(this);
        }
        private void button_Valider_MouseClick(object sender, MouseEventArgs e)
        {
            string          ChaineBd     = "Provider=SQLOLEDB;Data Source=INFO-joyeux;Initial Catalog=IMMOBILLY_JACKYTEAM;Persist Security Info=True; Integrated Security=sspi;";
            OleDbConnection dbConnection = new OleDbConnection(ChaineBd);

            dbConnection.Open();

            string       sql = "UPDATE SOUHAIT  set STATUT = '" + comboBox1.Text + "', SURFACE_HABITABLE_MIN = '" + textBox_SurfaceHabitable.Text + "', SURFACE_PARCELLE_MIN = '" + textBox_Parcelle.Text + "', NB_PIECES_MIN = '" + numericUpDown3.Text + "',  PRIX_MAX = '" + textBox2.Text + "' where CODE_SOUHAIT = '" + textBox1.Text + "' ";
            OleDbCommand cmd = new OleDbCommand(sql, dbConnection);

            cmd.ExecuteNonQuery();
            MessageBox.Show("Saved");

            FicheSouhaitsViz fsv = new FicheSouhaitsViz();

            fsv.Show(this);
            this.Hide();
        }