private void BtnNewClick(Object sender, EventArgs e) { var frmInvoice = new InvoiceForm(); frmInvoice.Initialise(MyConfiguration, MyCompanyFile, MyCredentials, MyOAuthKeyService); frmInvoice.Show(this); }
private void GridAllInvoicesCellContentDoubleClick(object sender, DataGridViewCellEventArgs e) { //Get the selected Invoice var invoice = ((Invoice[])GridAllInvoices.DataSource)[e.RowIndex]; switch (invoice.InvoiceType) { case InvoiceLayoutType.Service: //load the Invoice List var frmInvoice = new InvoiceForm(); frmInvoice.Initialise(MyConfiguration, MyCompanyFile, MyCredentials, MyOAuthKeyService); frmInvoice.Show(invoice); break; default: MessageBox.Show("Only Service Invoices Have been implemented"); break; } }
private void GridAllInvoicesCellContentDoubleClick(object sender,DataGridViewCellEventArgs e) { //Get the selected Invoice var invoice = ((Invoice[])GridAllInvoices.DataSource)[e.RowIndex]; switch (invoice.InvoiceType) { case InvoiceLayoutType.Service: //load the Invoice List var frmInvoice = new InvoiceForm(); frmInvoice.Initialise(MyConfiguration, MyCompanyFile, MyCredentials, MyOAuthKeyService); frmInvoice.Show(invoice); break; default: MessageBox.Show("Only Service Invoices Have been implemented"); break; } }