void KeyDownEvent(object sender, KeyEventArgs e) { if (bdsPXK.Position < 0) { return; } DataRow drCurrent = ((DataRowView)bdsPXK.Current).Row; switch (e.KeyCode) { case Keys.F9: //this.Filter(); break; case Keys.F7: switch (e.Modifiers) { case Keys.Shift: Design(); break; case Keys.Control: PrintVoucher.PrintInvoices(drCurrent["Ma_Px"].ToString()); break; } break; } }
void btPrintReport_Click(object sender, EventArgs e) { string strRPT = cbxReport_List.SelectedValue.ToString(); if (strRPT == "PXK") { Print(true); } else if (strRPT == "PXKLIST") { PrintListOrder(true); } else if (strRPT == "INVOICE") { if (bdsPXK.Position < 0) { return; } DataRow drCurrent = ((DataRowView)bdsPXK.Current).Row; PrintVoucher.PrintInvoices(drCurrent["Ma_Px"].ToString()); } else if (strRPT == "INVOICE_0") { if (bdsPXK.Position < 0) { return; } DataRow drCurrent = ((DataRowView)bdsPXK.Current).Row; PrintVoucher.PrintInvoices(drCurrent["Ma_Px"].ToString(), true, false); } else if (strRPT == "INVOICE_1") { if (bdsPXK.Position < 0) { return; } DataRow drCurrent = ((DataRowView)bdsPXK.Current).Row; PrintVoucher.PrintInvoices(drCurrent["Ma_Px"].ToString(), true, true); } else if (strRPT == "DTT02") { PrintDTT02(); } else if (strRPT == "DTT05") { PrintDTT05(); } else if (strRPT == "DTT05_1") { PrintDTT05_1(); } }