/// <summary> /// Print function /// </summary> public void Print() { try { if (dgvJournalReport.Rows.Count > 0) { string strFromDate = txtFromDate.Text; string strToDate = txtToDate.Text; decimal decVoucherTypeId = Convert.ToDecimal(cmbVoucherType.SelectedValue.ToString()); decimal decLedgerId = Convert.ToDecimal(cmbAccountLedger.SelectedValue.ToString()); JournalVoucherBll bllJournalMaster = new JournalVoucherBll(); DataSet dsJournalReport = bllJournalMaster.JournalReportPrinting(strFromDate, strToDate, decVoucherTypeId, decLedgerId, 1); frmReport frmReport = new frmReport(); frmReport.MdiParent = formMDI.MDIObj; frmReport.JournalreportReportPrinting(dsJournalReport); } } catch (Exception ex) { MessageBox.Show("JVREP6:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// Print function /// </summary> public void Print() { try { if (dgvJournalReport.Rows.Count > 0) { string strFromDate = txtFromDate.Text; string strToDate = txtToDate.Text; decimal decVoucherTypeId = Convert.ToDecimal(cmbVoucherType.SelectedValue.ToString()); decimal decLedgerId = Convert.ToDecimal(cmbAccountLedger.SelectedValue.ToString()); JournalMasterSP SpJournalMaster = new JournalMasterSP(); DataSet dsJournalReport = SpJournalMaster.JournalReportPrinting(strFromDate, strToDate, decVoucherTypeId, decLedgerId, 1); frmReport frmReport = new frmReport(); frmReport.MdiParent = formMDI.MDIObj; frmReport.JournalreportReportPrinting(dsJournalReport); } } catch (Exception ex) { formMDI.infoError.ErrorString = "JVREP6:" + ex.Message; } }