Exemple #1
0
        private void cbSave_Click(object sender, EventArgs e)
        {
            //MessageBox.Show(tbQSamp.Text.ToString());
            //MessageBox.Show(formMode1.ToString());
            //DataTable dtNum = Tools.GetGeneralNumerator(docNoPO, Tools.GeneralInitial());
            //lebar = int.Parse(dtNum.Rows[0]["Lebar"].ToString());
            //iNomor = int.Parse(dtNum.Rows[0]["Nomor"].ToString());
            //depan = Tools.GeneralInitial();
            //belakang = dtNum.Rows[0]["Belakang"].ToString();
            //iNomor++;
            //strNoPO = Tools.FormatNumerator(iNomor, lebar, depan, belakang);
            switch (formMode1)
            {
            case enumFormMode.New:
                InsertPODetail(strNoPO);
                break;

            case enumFormMode.Update:
                //UpdatePO();
                break;
            }
            frmPO frmCaller = (frmPO)this.Caller;

            frmCaller.RefreshHeader();
            this.Close();
        }
Exemple #2
0
        private void cbSave_Click(object sender, EventArgs e)
        {
            UpdatePODetail(strNoPO);
            frmPO frmCaller = (frmPO)this.Caller;

            frmCaller.RefreshHeader();
            this.Close();
        }
Exemple #3
0
        private void cmdSave_Click(object sender, EventArgs e)
        {
            DataTable dtNum = Tools.GetGeneralNumerator(docNoPO, Tools.GeneralInitial());

            lebar    = int.Parse(dtNum.Rows[0]["Lebar"].ToString());
            iNomor   = int.Parse(dtNum.Rows[0]["Nomor"].ToString());
            depan    = Tools.GeneralInitial();
            belakang = dtNum.Rows[0]["Belakang"].ToString();
            iNomor++;
            PO = Tools.FormatNumerator(iNomor, lebar, depan, belakang);
            SaveDataGrid(PO);

            frmPO frmCaller = (frmPO)this.Caller;

            frmCaller.RefreshHeader();
            this.Close();
        }
Exemple #4
0
        private void cbSave_Click(object sender, EventArgs e)
        {
            //MessageBox.Show(_headerRowId);
            //DataTable dtNum = Tools.GetGeneralNumerator(docNoPO, Tools.GeneralInitial());
            //lebar = int.Parse(dtNum.Rows[0]["Lebar"].ToString());
            //iNomor = int.Parse(dtNum.Rows[0]["Nomor"].ToString());
            ////depan = Tools.GeneralInitial();
            //depan =string.Empty;
            ////belakang = dtNum.Rows[0]["Belakang"].ToString();
            //if (DateTime.Today.Month.ToString().Length == 2)
            //{
            //    belakang = "/" + DateTime.Today.Month.ToString() +
            //    "/" + DateTime.Today.Year.ToString();
            //}
            //else
            //{
            //    belakang = "/0" + DateTime.Today.Month.ToString() +
            //    "/" + DateTime.Today.Year.ToString();
            //}
            //iNomor++;
            //strNoPO = Tools.FormatNumerator(iNomor, lebar, depan, belakang);

            ////strNoPO = GlobalVar.Gudang.ToString() + iNomor.ToString() + belakang;
            //    //2811140./04/2013

            if (validation())
            {
                switch (formMode)
                {
                case enumFormMode.New:
                    strNoPO = textBox1.Text;
                    InsertPO(strNoPO);
                    break;

                case enumFormMode.Update:
                    //UpdatePO();
                    break;
                }
            }
            frmPO frmCaller = (frmPO)this.Caller;

            frmCaller.RefreshHeader();
            this.Close();
        }