Ejemplo n.º 1
0
 //CONSTRUCTOR
 /// <summary>
 /// This is the constructor for the EquipmentMaintenanceForm. It initialazes the display of the form, initializes the class variables and bind the controls on the form the their corresponding data sources.
 /// </summary>
 /// <param name="dataModule">The DataModule object this application uses for database connection.</param>
 /// <param name="mainForm">The MainForm that was clicked to open this form.</param>
 public EquipmentMaintenanceForm(DataModule dataModule, MainForm mainForm)
 {
     this.InitializeComponent();
     this.dataModule = dataModule;
     this.mainForm = mainForm;
     this.BindControls();
 }
Ejemplo n.º 2
0
 //CONSTRUCTOR
 public ServiceTypeMaintenanceForm(DataModule dataModule, MainForm mainForm)
 {
     this.InitializeComponent();
     this.dataModule = dataModule;
     this.mainForm   = mainForm;
     this.BindControls();
 }
Ejemplo n.º 3
0
 /// <summary>
 /// The constructor for the PrintInvoicesForm. Initializes the display objects and variables for the form.
 /// </summary>
 /// <param name="dataModule">The DataModule object this application uses for database connection.</param>
 /// <param name="mainForm">The MainForm that was clicked to open this form.</param>
 public PrintInvoicesForm(DataModule dataModule, MainForm mainForm)
 {
     InitializeComponent();
     this.dataModule            = dataModule;
     this.mainForm              = mainForm;
     serviceCurrencyManager     = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICE"];
     ownerCurrencyManager       = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "OWNER"];
     vehicleCurrencyManager     = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "VEHICLE"];
     serviceTypeCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICETYPE"];
     blackBrush = new SolidBrush(Color.Black);
     this.printPreviewDialog.Document = reportPrintDocument;
 }
Ejemplo n.º 4
0
 /// <summary>
 /// The constructor for the PrintInvoicesForm. Initializes the display objects and variables for the form.
 /// </summary>
 /// <param name="dataModule">The DataModule object this application uses for database connection.</param>
 /// <param name="mainForm">The MainForm that was clicked to open this form.</param>
 public PrintInvoicesForm(DataModule dataModule, MainForm mainForm)
 {
     InitializeComponent();
     this.dataModule = dataModule;
     this.mainForm = mainForm;
     serviceCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICE"];
     ownerCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "OWNER"];
     vehicleCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "VEHICLE"];
     serviceTypeCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICETYPE"];
     blackBrush = new SolidBrush(Color.Black);
     this.printPreviewDialog.Document = reportPrintDocument;
 }
Ejemplo n.º 5
0
 //CONSTRUCTOR
 public ServiceMaintenanceForm(DataModule dataModule, MainForm mainForm)
 {
     this.InitializeComponent();
     this.dataModule            = dataModule;
     this.mainForm              = mainForm;
     serviceCurrencyManager     = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICE"];
     vehicleCurrencyManager     = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "VEHICLE"];
     ownerCurrencyManager       = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "OWNER"];
     serviceTypeCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICETYPE"];
     this.BindControls();
     //changing data grid view column widths.
     this.setColumnWidths(serviceDataGridView, 80);
 }
Ejemplo n.º 6
0
 //CONSTRUCTOR
 public ServiceMaintenanceForm(DataModule dataModule, MainForm mainForm)
 {
     this.InitializeComponent();
     this.dataModule = dataModule;
     this.mainForm = mainForm;
     serviceCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICE"];
     vehicleCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "VEHICLE"];
     ownerCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "OWNER"];
     serviceTypeCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICETYPE"];
     this.BindControls();
     //changing data grid view column widths.
     this.setColumnWidths(serviceDataGridView, 80);
 }
Ejemplo n.º 7
0
 //CONSTRUCTOR
 /// <summary>
 /// The constructor for the AllocateEquipmentForm. Initializes the objects variables and lays out the data grid views.
 /// </summary>
 /// <param name="dataModule">The DataModule object this application uses for database connection.</param>
 /// <param name="mainForm">The mainform object that contains the allocate equipment button that was clicked to show this form.</param>
 public AllocateEquipmentForm(DataModule dataModule, MainForm mainForm)
 {
     this.InitializeComponent();
     this.dataModule = dataModule;
     this.mainForm = mainForm;
     //creating currency managers for the various data grid views.
     equipmentCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "EQUIPMENT"];
     serviceTypeCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICETYPE"];
     serviceTypeEquipmentCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICETYPEEQUIPMENT"];
     this.BindControls();
     //changing data grid view column widths.
     this.setColumnWidths(serviceTypeDataGridView, 80);
     this.serviceTypeDataGridView.Columns[1].Width = 106;
     this.setColumnWidths(equipmentDataGridView, 90);
     this.equipmentDataGridView.Columns[1].Width = 160;
     this.setColumnWidths(serviceTypeEquipmentDataGridView, 80);
 }
Ejemplo n.º 8
0
 //CONSTRUCTOR
 /// <summary>
 /// The constructor for the AllocateEquipmentForm. Initializes the objects variables and lays out the data grid views.
 /// </summary>
 /// <param name="dataModule">The DataModule object this application uses for database connection.</param>
 /// <param name="mainForm">The mainform object that contains the allocate equipment button that was clicked to show this form.</param>
 public AllocateEquipmentForm(DataModule dataModule, MainForm mainForm)
 {
     this.InitializeComponent();
     this.dataModule = dataModule;
     this.mainForm   = mainForm;
     //creating currency managers for the various data grid views.
     equipmentCurrencyManager            = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "EQUIPMENT"];
     serviceTypeCurrencyManager          = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICETYPE"];
     serviceTypeEquipmentCurrencyManager = (CurrencyManager)this.BindingContext[dataModule.greenDataSet, "SERVICETYPEEQUIPMENT"];
     this.BindControls();
     //changing data grid view column widths.
     this.setColumnWidths(serviceTypeDataGridView, 80);
     this.serviceTypeDataGridView.Columns[1].Width = 106;
     this.setColumnWidths(equipmentDataGridView, 90);
     this.equipmentDataGridView.Columns[1].Width = 160;
     this.setColumnWidths(serviceTypeEquipmentDataGridView, 80);
 }
Ejemplo n.º 9
0
 //MISC FUNCTIONS
 /// <summary>
 /// Function that runs when the main forms loads - creates a DataModule object.
 /// </summary>
 /// <param name="sender">The object that called this function. In this case the mainForm.</param>
 /// <param name="e">The event arguments for the onLoad event passed to this function.</param>
 private void MainForm_Load(object sender, EventArgs e)
 {
     dataModule = new DataModule();
 }
Ejemplo n.º 10
0
 //MISC FUNCTIONS
 /// <summary>
 /// Function that runs when the main forms loads - creates a DataModule object.
 /// </summary>
 /// <param name="sender">The object that called this function. In this case the mainForm.</param>
 /// <param name="e">The event arguments for the onLoad event passed to this function.</param>
 private void MainForm_Load(object sender, EventArgs e)
 {
     dataModule = new DataModule();
 }