Пример #1
0
        private void SearchCustomerBtn_Click(object sender, EventArgs e)
        {
            OrderFindSupplier FindSupplier = new OrderFindSupplier();

            FindSupplier.FormClosing += (object sender2, FormClosingEventArgs e2) =>
            {
                if (FindSupplier.ReturnSupplierId() != null)
                {
                    this.IdSupplierTxt.Text   = FindSupplier.ReturnSupplierId();
                    this.NameSupplierTxt.Text = FindSupplier.ReturnSupplierName();
                    this.AfmSupplierTxt.Text  = FindSupplier.ReturnSupplierAfm();
                    SupplierOccupation        = FindSupplier.ReturnSupplierOccupation();
                    SupplierAddress           = FindSupplier.ReturnSupplierAddress();
                    SupplierTk         = FindSupplier.ReturnSupplierTk();
                    SupplierTax_office = FindSupplier.ReturnSupplierTax_office();
                    SupplierPhone      = FindSupplier.ReturnSupplierPhone();
                    SupplierEmail      = FindSupplier.ReturnSupplierEmail();
                    SupplierPhone2     = FindSupplier.ReturnSupplierPhone2();
                    SupplierRegion     = FindSupplier.ReturnSupplierRegion();
                }
            };
            FindSupplier.FormClosed += new FormClosedEventHandler(FormClose);
            FindSupplier.FormClosed += (object sender3, FormClosedEventArgs e3) =>
            {
                this.SuspendLayout();
                FindSupplier.Dispose();
                this.ResumeLayout(false);
            };
            this.Enabled = false;
            FindSupplier.ShowDialog();
        }
Пример #2
0
        private void SearchSupplierBtn_Click(object sender, EventArgs e)
        {
            OrderFindSupplier FindSupplier = new OrderFindSupplier();

            FindSupplier.FormClosing += (object sender2, FormClosingEventArgs e2) =>
            {
                if (FindSupplier.ReturnSupplierId() != null)
                {
                    this.IdSupplierTxt.Text   = FindSupplier.ReturnSupplierId();
                    this.NameSupplierTxt.Text = FindSupplier.ReturnSupplierName();
                    this.AfmSupplierTxt.Text  = FindSupplier.ReturnSupplierAfm();
                }
            };
            FindSupplier.FormClosed += new FormClosedEventHandler(FormClose);
            this.Enabled             = false;
            FindSupplier.ShowDialog();
        }
Пример #3
0
        private void SearchSupplierBtn_Click(object sender, EventArgs e)
        {
            OrderFindSupplier FindSupplier = new OrderFindSupplier();

            FindSupplier.FormClosing += (object sender2, FormClosingEventArgs e2) =>
            {
                if (FindSupplier.ReturnSupplierId() != null)
                {
                    ClearValues();
                    if (Convert.ToInt16(ProdItemsTxt.Text.ToString()) > 1)
                    {
                        ClearProds();
                    }
                    this.IdSupplierTxt.Text        = FindSupplier.ReturnSupplierId();
                    this.NameSupplierTxt.Text      = FindSupplier.ReturnSupplierName();
                    this.AfmSupplierTxt.Text       = FindSupplier.ReturnSupplierAfm();
                    this.PrevDebitSupplierTxt.Text = FindSupplier.ReturnSupplierDebit();
                }
            };
            FindSupplier.FormClosed += new FormClosedEventHandler(FormClose);
            this.Enabled             = false;
            FindSupplier.ShowDialog();
        }