示例#1
0
        private void PARCOURIR_LISTE_CLIENT_Click(object sender, EventArgs e)
        {
            CHM_COMMANDE_CLIENT c_clt = new CHM_COMMANDE_CLIENT();

            c_clt.client_selection_event += new CHM_COMMANDE_CLIENT.client_selection(c_clt_client_selection_event);
            c_clt.ShowDialog();
        }
示例#2
0
        private void FICHE_FACTURE_KeyDown(object sender, KeyEventArgs e)
        {
            if (REF_CLIENT.Focused && e.KeyCode == Keys.Enter && REF_CLIENT.Text != "")
            {
                Application.DoEvents();
                //DataTable dt = CLIENT_APP_PARAM.GEST.P_COMMANDE.RECHERCHE_CLIENT(this.REF_CLIENT.Text);
                DataTable dt = CLIENT_APP_PARAM.gcws.RECHERCHE_CLIENT(this.REF_CLIENT.Text);
                if (dt.Rows.Count != 0)
                {
                    CODE_CLIENT          = dt.Rows[0]["CODE_CLIENT"].ToString();
                    RS_CLIENT.Text       = dt.Rows[0]["RS_CLIENT"].ToString();
                    CODE_MAG             = dt.Rows[0]["CODE_MAG"].ToString();
                    dt_b_liv             = CLIENT_APP_PARAM.gcws.LOAD_B_LIV_CLIENT_NON_GENERE(CODE_CLIENT);
                    bs_b_liv.DataSource  = dt_b_liv;
                    dgv_b_liv.DataSource = bs_b_liv;

                    calculMontantTotal();
                }
                else
                {
                    CODE_CLIENT    = "-1";
                    RS_CLIENT.Text = "Référence invalide !";
                }
            }

            if (e.KeyCode == Keys.Enter && REF_CLIENT.Focused && REF_CLIENT.Text.Trim() == "")
            {
                CHM_COMMANDE_CLIENT f = new CHM_COMMANDE_CLIENT();
                f.client_selection_event += new CHM_COMMANDE_CLIENT.client_selection(f_client_selection_event);
                f.ShowDialog();
            }
            if (e.KeyCode == Keys.F5)
            {
                if (button1.Enabled)
                {
                    button1.PerformClick();
                }
            }
            if (e.KeyCode == Keys.F8)
            {
                if (BTN_APERçU.Enabled)
                {
                    BTN_APERçU.PerformClick();
                }
            }
            if (e.KeyCode == Keys.F12)
            {
                if (BTN_REGLEMENT.Enabled)
                {
                    BTN_REGLEMENT.PerformClick();
                }
            }
            if (e.KeyCode == Keys.F10)
            {
                if (BTN_ENREGISTRER.Enabled)
                {
                    BTN_ENREGISTRER.PerformClick();
                }
            }
        }
示例#3
0
        private void PARCOURIR_LISTE_CLIENT_Click(object sender, EventArgs e)
        {
            CHM_COMMANDE_CLIENT f = new CHM_COMMANDE_CLIENT();

            f.StartPosition           = FormStartPosition.CenterScreen;
            f.client_selection_event += new CHM_COMMANDE_CLIENT.client_selection(f_client_selection_event);
            f.ShowDialog();
        }
示例#4
0
 private void btn_client_Click(object sender, EventArgs e)
 {
     try
     {
         CHM_COMMANDE_CLIENT f = new CHM_COMMANDE_CLIENT();
         f.client_selection_event += new CHM_COMMANDE_CLIENT.client_selection(f_client_selection_event);
         f.StartPosition           = FormStartPosition.CenterScreen;
         f.ShowDialog();
     }
     catch (Exception er)
     {
         MessageBox.Show(er.Message, this.Text, MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
示例#5
0
 private void RS_CLIENT_Click(object sender, EventArgs e)
 {
     try
     {
         if (RS_CLIENT.Text != "")
         {
             CLIENT_APP_PARAM.ds_param.bsClient.Position = CLIENT_APP_PARAM.ds_param.bsClient.Find("CODE_CLIENT", CODE_CLIENT);
             CHM_FICHE_CLIENT f = new CHM_FICHE_CLIENT(CLIENT_APP_PARAM.ds_param.bsClient);
             f.ShowDialog();
         }
         else
         {
             CHM_COMMANDE_CLIENT c = new CHM_COMMANDE_CLIENT();
             c.client_selection_event += new CHM_COMMANDE_CLIENT.client_selection(c_client_selection_event);
             c.ShowDialog();
         }
     }
     catch (Exception er)
     {
         MessageBox.Show(er.Message);
     }
 }
示例#6
0
        private void CHM_FICHE_COMMANDE_KeyDown(object sender, KeyEventArgs e)
        {
            if (this.REF_CLIENT.Focused && e.KeyCode == Keys.Enter && this.REF_CLIENT.Text != "")
            {
                Application.DoEvents();
                //DataTable dt = CLIENT_APP_PARAM.GEST.P_COMMANDE.RECHERCHE_CLIENT(this.REF_CLIENT.Text);
                DataTable dt = CLIENT_APP_PARAM.gcws.RECHERCHE_CLIENT(this.REF_CLIENT.Text);
                if (dt.Rows.Count != 0)
                {
                    this.CODE_CLIENT    = dt.Rows[0]["CODE_CLIENT"].ToString();
                    this.RS_CLIENT.Text = dt.Rows[0]["RS_CLIENT"].ToString();
                }
                else
                {
                    this.CODE_CLIENT    = "-1";
                    this.RS_CLIENT.Text = "Référence invalide !";
                }
            }
            if (this.REF_CLIENT.Focused && e.KeyCode == Keys.Enter && this.REF_CLIENT.Text.Trim() == "")
            {
                CHM_COMMANDE_CLIENT c_clt = new CHM_COMMANDE_CLIENT();
                c_clt.client_selection_event += new CHM_COMMANDE_CLIENT.client_selection(c_clt_client_selection_event);
                c_clt.ShowDialog();
            }

            if (e.KeyCode == Keys.F5)
            {
                if (entete_Formulaire_21.btn_refresh.Enabled)
                {
                    entete_Formulaire_21.btn_refresh.PerformClick();
                }
            }
            if (e.KeyCode == Keys.F6)
            {
                if (buttonAJOUTER.Enabled)
                {
                    buttonAJOUTER.PerformClick();
                }
            }
            if (e.KeyCode == Keys.Delete)
            {
                if (buttonSUPPRIMER.Enabled)
                {
                    buttonSUPPRIMER.PerformClick();
                }
            }
            if (e.KeyCode == Keys.F10)
            {
                if (buttonENREGISTRER.Enabled)
                {
                    buttonENREGISTRER.PerformClick();
                }
            }
            if (e.KeyCode == Keys.F8)
            {
                if (BTN_Aperçu_cmd.Enabled)
                {
                    BTN_Aperçu_cmd.PerformClick();
                }
            }
            if (e.KeyCode == Keys.F11)
            {
                if (BTN_B_LIV.Enabled)
                {
                    BTN_B_LIV.PerformClick();
                }
            }
            if (e.KeyCode == Keys.Control && e.KeyCode == Keys.L)
            {
                if (btn_liste_commande.Enabled)
                {
                    btn_liste_commande.PerformClick();
                }
            }
        }