private void popupCustomize_Closed(object sender, EventArgs e) { InvoiceSetting _pref_PurchaseInvoice = new InvoiceSetting(); popupCustomize.PopupAnimation = System.Windows.Controls.Primitives.PopupAnimation.Fade; InvoiceSetting.Default.Save(); _pref_PurchaseInvoice = InvoiceSetting.Default; popupCustomize.IsOpen = false; }
private void toolBar_btnNew_Click(object sender) { InvoiceSetting _pref_PurchaseInvoice = new InvoiceSetting(); purchase_invoice purchase_invoice = PurchaseInvoiceDB.New(); purchase_invoice.trans_date = DateTime.Now.AddDays(_pref_PurchaseInvoice.TransDate_OffSet); PurchaseInvoiceDB.Entry(purchase_invoice).State = EntityState.Added; purchase_invoiceViewSource.View.MoveCurrentToLast(); }