Example #1
0
        private void BindEditForm(object[] data)
        {
            customerBAL = new BAL.CustomerBAL();
            DataTable table = new DataTable();

            table = customerBAL.getCustomers(data);
            BindFields(table);
        }
Example #2
0
        private DataTable GetCustomerTableToExport()
        {
            customerBAL = new BAL.CustomerBAL();
            DataTable table = new DataTable();

            table = customerBAL.getCustomersForExcel();
            return(table);
        }
Example #3
0
 public Challan()
 {
     InitializeComponent();
     customerBAL = new BAL.CustomerBAL();
     materialBAL = new BAL.MaterialBAL();
     orderBAL    = new BAL.OrderBAL();
     BindCustomer();
     BindProducts();
 }
Example #4
0
        private void BindCustomerGrid(object[] data)
        {
            customerBAL = new BAL.CustomerBAL();
            DataTable table = new DataTable();

            table = customerBAL.getCustomers(data);
            this.dataGridCustomer.RowPostPaint += new System.Windows.Forms.DataGridViewRowPostPaintEventHandler(this.dataGridSupplier_RowPostPaint);
            dataGridCustomer.DataSource         = table;
            this.dataGridCustomer.Columns["CustomerId"].Visible = false;
            // Auto Resize
            dataGridCustomer.AutoResizeColumns();
            dataGridCustomer.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.AllCells;

            BindAutoCompleteToCustomer(table);
        }
Example #5
0
        private void btnYes_Click(object sender, EventArgs e)
        {
            switch (OfModule)
            {
            case "User":
                BAL.UserBAL userBAL = new BAL.UserBAL();
                if (userBAL.deleteUser(ToDeleteId))
                {
                    MessageBox.Show("Deleted Successfully");
                    this.Close();
                }
                break;

            case "Customer":
                BAL.CustomerBAL customerBAL = new BAL.CustomerBAL();
                if (customerBAL.deleteCustomer(ToDeleteId))
                {
                    MessageBox.Show("Deleted Successfully");
                    this.Close();
                }
                break;

            case "Supplier":
                BAL.SupplierBAL supplierBAL = new BAL.SupplierBAL();
                if (supplierBAL.deleteSupplier(ToDeleteId))
                {
                    MessageBox.Show("Deleted Successfully");
                    this.Close();
                }
                break;

            case "Material":
                BAL.MaterialBAL materialBAL = new BAL.MaterialBAL();
                if (materialBAL.deleteMaterial(ToDeleteId))
                {
                    MessageBox.Show("Deleted Successfully");
                    this.Close();
                }
                break;

            default:
                break;
            }
        }
Example #6
0
 public EditCustomer(int CustomerId)
 {
     InitializeComponent();
     customerBAL = new BAL.CustomerBAL();
     BindEditForm(new object[] { CustomerId, "" });
 }
Example #7
0
 public AddCustomer()
 {
     InitializeComponent();
     customerBAL = new BAL.CustomerBAL();
 }
Example #8
0
 public CutomerImport()
 {
     InitializeComponent();
     customerBAL = new BAL.CustomerBAL();
 }