private void addRecord() { if (isFormValidate()) { setObjects(); HANDLER.ShowMessage(txtMessage, HandlerToDB.InsertOrUpdate(ConfigFormNames.CUSTOMER_NEW, ConfigQueryModes.INSERT) + " " + ConfigApp.INSERT_MESSAGE); txtCusCusCode.AdvanceText = HandlerToDB.GetNewID(ConfigFormNames.CUSTOMER_NEW).ToString(); clearForm(); } else { HANDLER.ShowMessage(txtMessage, ConfigApp.NOT_VALID_FORM_MESSAGE); } }
private void btnAdd_Click(object sender, EventArgs e) { if (formValidate()) { setObjects(); HANDLER.ShowMessage(txtMessage, HandlerToDB.InsertOrUpdate(ConfigFormNames.SALES, ConfigQueryModes.INSERT) + " " + ConfigApp.INSERT_MESSAGE); currentSgate = Stage.Locked; clearForm(); btnNewInvoice.Enabled = true; txtSalesNo.AdvanceText = HandlerToDB.GetNewID(ConfigFormNames.SALES).ToString(); salesDataGrid.DataSource = HandlerToDB.GetDataTableWhere(ConfigSelectQueryModes.CURRENT_SALE_INVOICE_MODE); } else { HANDLER.ShowMessage(txtMessage, ConfigApp.NOT_VALID_FORM_MESSAGE); } }
private void callOnLoad() { lblModePro.Text = ConfigApp.SEARCH_MODE_ID_MESSAGE; ModeIDPRO = true; lblMode.Text = ConfigApp.SEARCH_MODE_ID_MESSAGE; ModeID = true; companyList = new DataTable(); productList = new DataTable(); ProDataGrid.DataSource = productList = HandlerToDB.GetDataTable(ConfigSelectQueries.ALL_PRODUCTS); ComDataGrid.DataSource = companyList = HandlerToDB.GetDataTable(ConfigSelectQueries.ALL_COMPANY); DateExpiry.CustomFormat = ConfigApp.DATETIME_EXPIRY_FORMATE; DateTime now = DateTime.Now; DateExpiry.MinDate = new DateTime(now.Year + ConfigApp.STOCK_EXPIRY_MIN_Y, now.Month + ConfigApp.STOCK_EXPIRY_MIN_M, now.Day + ConfigApp.STOCK_EXPIRY_MIN_D); dateInvoice.CustomFormat = ConfigApp.DATETIME_FORMATE; dateInvoice.MinDate = DateTime.Now; HandlerToDB.SetComboBox(combSTMode, ConfigSelectQueries.SALES_TAX_MODE); HandlerToDB.SetComboBox(combDisMode, ConfigSelectQueries.DISCOUNT_MODE); txtStockCode.AdvanceText = HandlerToDB.GetNewID(ConfigFormNames.STOCK_NEW).ToString(); }
private void callOnLoad() { HandlerToDB.SetComboBox(combZone, ConfigFormNames.CITY_NEW); txtSalesManCode.AdvanceText = HandlerToDB.GetNewID(ConfigFormNames.SALES_MAN_NEW).ToString(); }
private void ZoneNew_Load(object sender, EventArgs e) { txtZCode.AdvanceText = HandlerToDB.GetNewID(ConfigFormNames.ZONE_NEW).ToString(); }
private void CityNew_Load(object sender, EventArgs e) { HandlerToDB.SetComboBox(combZoneName, ConfigFormNames.CITY_NEW); txtCCode2.AdvanceText = HandlerToDB.GetNewID(ConfigFormNames.CITY_NEW).ToString(); }
private void Company_Load(object sender, EventArgs e) { txtCCode.AdvanceText = HandlerToDB.GetNewID(ConfigFormNames.COMPANY).ToString(); // txtCName.AdvanceText = DateTime.Now.ToString(); }