public StrataSetupWizard(CruiseDesignMain Main, string dalPathRecon, bool recExists) { this.Main = Main; this.cdDAL = Main.cdDAL; InitializeComponent(); reconExists = recExists; if (reconExists) { //reconExists = true; try { this.rDAL = new DAL(dalPathRecon); } catch (System.IO.IOException e) { Logger.Log.E(e); MessageBox.Show("Error: Cannot open recon file"); } catch (System.Exception e) { Logger.Log.E(e); MessageBox.Show("Error: Cannot open recon file"); } } else { MessageBox.Show("No Recon File Found.\nMake sure Recon file is in same Folder as the design file.\nDesign can still be created manually, but no Recon data will be used.", "Warning", MessageBoxButtons.OK); } //check for historical data InitializeDataBindings(); checkSalePurpose(); InitializePages(); }
public CostSetupForm(CruiseDesignMain Main) { InitializeComponent(); /* try { this.cdDAL = new DAL(dalPathDesign); } catch (System.IO.IOException e) { Logger.Log.E(e); MessageBox.Show("Error: Cannot open recon file"); //TODO display error message to user } catch (System.Exception e) { Logger.Log.E(e); MessageBox.Show("Error: Cannot open recon file"); } */ cdDAL = Main.cdDAL; InitializeForm(); }
public HistoricalSetupWizard(CruiseDesignMain Main, bool canCreateNew) { InitializeComponent(); /* try { this.cdDAL = new DAL(dalPathDesign, canCreateNew); } catch (System.IO.IOException e) { Logger.Log.E(e); //TODO display error message to user } catch (System.Exception e) { Logger.Log.E(e); } */ cdDAL = Main.cdDAL; createNew = canCreateNew; setSalePurpose(); InitializeDataBindings(); InitializePages(); }