public VendorOrderSheetForm() { InitializeComponent(); MasterFilePath = CommonFunctions.MasterFilePath; txtBoxSaveFolderPath.Text = System.IO.Path.GetDirectoryName(MasterFilePath); ListColors = new List <Color>(); ListColors.Add(Color.FromArgb(184, 204, 228)); ListColors.Add(Color.FromArgb(218, 238, 243)); ListColors.Add(Color.FromArgb(216, 228, 188)); ListColors.Add(Color.FromArgb(228, 223, 236)); ListColors.Add(Color.FromArgb(255, 255, 153)); ListColors.Add(Color.FromArgb(224, 224, 224)); ListColors.Add(Color.FromArgb(178, 255, 102)); ListColors.Add(Color.FromArgb(255, 178, 102)); ListColors.Add(Color.FromArgb(255, 153, 153)); ListColors.Add(Color.FromArgb(51, 255, 153)); CommonFunctions.ResetProgressBar(); lblStatus.Text = ""; cmbBoxTimePeriodUnits.Items.Clear(); cmbBoxTimePeriodUnits.Items.Add("Days"); cmbBoxTimePeriodUnits.Items.Add("Weeks"); cmbBoxTimePeriodUnits.Items.Add("Months"); cmbBoxTimePeriodUnits.Items.Add("Years"); cmbBoxTimePeriodUnits.SelectedIndex = (Int32)CommonFunctions.ObjPurchaseOrderSettings.PastSalePeriodUnits; numUpDownTimePeriod.Value = CommonFunctions.ObjPurchaseOrderSettings.PastSalePeriodValue; openFileDialog1.Multiselect = false; openFileDialog1.CheckFileExists = true; openFileDialog1.CheckPathExists = true; txtBoxProductInventoryFile.Text = Path.GetDirectoryName(MasterFilePath) + @"\ProductInventory.xlsx"; txtBoxProductStockHistoryFile.Text = Path.GetDirectoryName(MasterFilePath) + @"\ProductStockHistory.xlsx"; }
public SellerOrderSheetForm() { try { InitializeComponent(); MasterFilePath = CommonFunctions.MasterFilePath; txtBoxOutputFolder.Text = System.IO.Path.GetDirectoryName(MasterFilePath); ListColors = new List <Color>(); ListColors.Add(Color.FromArgb(184, 204, 228)); ListColors.Add(Color.FromArgb(218, 238, 243)); ListColors.Add(Color.FromArgb(216, 228, 188)); ListColors.Add(Color.FromArgb(228, 223, 236)); ListColors.Add(Color.FromArgb(255, 255, 153)); ListColors.Add(Color.FromArgb(224, 224, 224)); ListColors.Add(Color.FromArgb(178, 255, 102)); ListColors.Add(Color.FromArgb(255, 178, 102)); ListColors.Add(Color.FromArgb(255, 153, 153)); ListColors.Add(Color.FromArgb(51, 255, 153)); CommonFunctions.ResetProgressBar(); } catch (Exception ex) { CommonFunctions.ShowErrorDialog("SellerOrderSheetForm.ctor()", ex); } }
void ShowChildForm(Form ObjForm) { try { if (MdiChildren.Length > 0) { return; } CommonFunctions.ResetProgressBar(); CommonFunctions.CurrentForm = ObjForm; ObjForm.MdiParent = this; ObjForm.ShowIcon = false; ObjForm.ShowInTaskbar = false; ObjForm.MinimizeBox = false; ObjForm.MaximizeBox = false; ObjForm.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; ObjForm.StartPosition = FormStartPosition.CenterScreen; ObjForm.FormClosed += new FormClosedEventHandler(ChildFormClosed); ObjForm.Show(); } catch (Exception ex) { CommonFunctions.ShowErrorDialog("MainForm.ShowChildForm()", ex); } }
private void bgWorkerCreatePO_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e) { CommonFunctions.ResetProgressBar(); CommonFunctions.ToggleEnabledPropertyOfAllControls(this); lblStatus.Enabled = true; btnClose.Focus(); }
private void bgWorkerOrderMaster_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e) { try { CommonFunctions.ResetProgressBar(); btnClose.Focus(); } catch (Exception ex) { CommonFunctions.ShowErrorDialog("OrderMasterForm.bgWorkerOrderMaster_RunWorkerCompleted()", ex); } }
private void backgroundWorker1_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e) { try { CommonFunctions.ResetProgressBar(); btnCreateOrderSheet.Enabled = true; btnCancel.Enabled = true; btnCancel.Focus(); } catch (Exception ex) { CommonFunctions.ShowErrorDialog("SellerOrderSheetForm.backgroundWorker1_RunWorkerCompleted()", ex); } }
private void bgWorkerSellerHistory_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e) { try { CommonFunctions.ResetProgressBar(); btnCreateReport.Enabled = true; btnClose.Enabled = true; btnClose.Focus(); } catch (Exception ex) { CommonFunctions.ShowErrorDialog("SellerHistoryReportForm.bgWorkerSellerHistory_RunWorkerCompleted()", ex); } }
public VendorPurchaseOrderForm() { InitializeComponent(); MasterFilePath = CommonFunctions.MasterFilePath; txtBoxOutputFolder.Text = System.IO.Path.GetDirectoryName(MasterFilePath); CommonFunctions.ResetProgressBar(); lblStatus.Text = ""; CommonFunctions.ListSelectedVendors.Clear(); dateTimePO.Value = DateTime.Now; txtBoxVendorOrderSheet.Text = txtBoxOutputFolder.Text + @"\VendorOrder_" + dateTimePO.Value.ToString("dd-MM-yyyy") + ".xlsx"; FillLineFromOrderMaster(); }
private void bgWorkerUpdPurchasesForm_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e) { try { CommonFunctions.ResetProgressBar(); btnUpdate.Enabled = true; btnClose.Enabled = true; btnBrowseVendorPOFile.Enabled = true; btnBrowseVendorHistory.Enabled = true; btnBrowseProductInvFile.Enabled = true; btnBrowseProductStockHistFile.Enabled = true; btnClose.Focus(); } catch (Exception ex) { CommonFunctions.ShowErrorDialog("UpdateProductPurchasesForm.bgWorkerUpdPurchasesForm_RunWorkerCompleted()", ex); } }
public UpdateOrderMasterForm() { InitializeComponent(); OrderMasterFilePath = CommonFunctions.MasterFilePath; lblStatus.Text = ""; CommonFunctions.ResetProgressBar(); chkBoxUpdSellerMaster.Checked = true; chkBoxUpdSellerHistory.Checked = true; chkBoxUpdProductSales.Checked = false; chkBoxUpdProductSales_CheckedChanged(null, null); groupBoxHistoryUpdate.Enabled = false; btnUpdate.Enabled = false; FileDialgSellerSummary.Multiselect = false; CommonFunctions.ObjProductMaster.ResetStockProducts(); }
public UpdateProductPurchasesForm() { InitializeComponent(); CommonFunctions.ResetProgressBar(); lblStatus.Text = ""; openFileDialog1.Multiselect = false; openFileDialog1.CheckFileExists = true; openFileDialog1.CheckPathExists = true; groupBoxProductVendorFiles.Enabled = false; btnUpdate.Enabled = false; btnClose.Enabled = true; chkBoxUpdProductInventory.Checked = true; chkBoxUpdStockHistory.Checked = true; chkBoxUpdVendorHistory.Checked = true; CommonFunctions.ObjProductMaster.ResetStockProducts(); }
private void btnOK_Click(object sender, EventArgs e) { try { CommonFunctions.MasterFilePath = txtBoxMasterFilePath.Text; CommonFunctions.ResetProgressBar(); btnOK.Enabled = false; #if DEBUG LoadDetailsFromOrderMaster(); #else ReportProgress = bgWorkerOrderMaster.ReportProgress; bgWorkerOrderMaster.RunWorkerAsync(); bgWorkerOrderMaster.WorkerReportsProgress = true; #endif } catch (Exception ex) { CommonFunctions.ShowErrorDialog("OrderMasterForm.btnOK_Click()", ex); } }
public SellerHistoryReportForm() { try { InitializeComponent(); chkBoxDateFilter.Checked = false; dateTimePickerStart.Format = DateTimePickerFormat.Custom; dateTimePickerStart.CustomFormat = "dd-MMM-yyyy"; dateTimePickerStart.Value = DateTime.Now.Date; dateTimePickerStart.Enabled = false; dateTimePickerEnd.Format = DateTimePickerFormat.Custom; dateTimePickerEnd.CustomFormat = "dd-MMM-yyyy"; dateTimePickerEnd.Value = DateTime.Now.Date; dateTimePickerEnd.Enabled = false; CommonFunctions.ResetProgressBar(); lblStatus.Text = ""; FillSellerList(); txtBoxSellerHistoryFilePath.Text = Path.GetDirectoryName(CommonFunctions.MasterFilePath) + @"\SellerHistory.xlsx"; SellerHistoryFilePath = txtBoxSellerHistoryFilePath.Text; txtBoxSaveFolderPath.Text = Path.GetDirectoryName(CommonFunctions.MasterFilePath); SaveFolderPath = txtBoxSaveFolderPath.Text; btnCreateReport.Focus(); } catch (Exception ex) { CommonFunctions.ShowErrorDialog("SellerHistoryReportForm.ctor()", ex); } }
private void backgroundWorker1_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e) { CommonFunctions.ResetProgressBar(); btnClose.Focus(); }