Ejemplo n.º 1
0
 /// <summary>
 /// Function to print report
 /// </summary>
 /// <param name="fromDate"></param>
 /// <param name="toDate"></param>
 public void Print(DateTime fromDate, DateTime toDate)
 {
     try
     {
         FinancialStatementSP spFinance = new FinancialStatementSP();
         AccountGroupSP spAccountGroup = new AccountGroupSP();
         DataSet dsAccountGroup = new DataSet();
         DataTable dtblAccountGroup = spAccountGroup.AccountGroupReportFill(fromDate, toDate);
         string strSum = lblBalanceTotal.Text;
         DataTable dtblSum = new DataTable();
         dtblSum.Columns.Add("Sum", typeof(string));
         DataRow dr = dtblSum.NewRow();
         dr[0] = strSum;
         dtblSum.Rows.InsertAt(dr, 0);
         
         DataTable dtblCompany = spFinance.FundFlowReportPrintCompany(1);
         dsAccountGroup.Tables.Add(dtblAccountGroup);
         dsAccountGroup.Tables.Add(dtblCompany);
         dsAccountGroup.Tables.Add(dtblSum);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.AccountGroup(dsAccountGroup);
     }
     catch (Exception ex)
     {
         MessageBox.Show("AGR:1" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 2
0
 public void Print()
 {
     try
     {
         PaymentMasterSP SpPaymentMaster = new PaymentMasterSP();
         DataSet dsPaymentReport = SpPaymentMaster.PaymentReportPrinting(Convert.ToDateTime(dtpFromDate.Value.ToString()), Convert.ToDateTime(dtpToDate.Value.ToString()), Convert.ToDecimal(cmbLedger.SelectedValue), Convert.ToDecimal(cmbVoucherType.SelectedValue), Convert.ToDecimal(cmbBankOrCash.SelectedValue), 1);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.PaymentReportPrinting(dsPaymentReport);
     }
     catch (Exception ex)
     {
         MessageBox.Show("PRP1:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// On 'Print' button click to print
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvPayHead.RowCount > 0)
         {
             DataSet ds = new DataSet();
             PayHeadBll BllPayHead = new PayHeadBll();
             List<DataTable> listObj = BllPayHead.PayHeadViewAllForPayHeadReport(cmbPayHead.Text, cmbType.Text);
             //CompanySP spCompany = new CompanySP();
             CompanyCreationBll bllCompanyCreation = new CompanyCreationBll();
             List<DataTable> listObjCompany = bllCompanyCreation.CompanyViewDataTable(1);
             frmReport frmreport = new frmReport();
             frmreport.MdiParent = formMDI.MDIObj;
             ds.Tables.Add(listObj[0]);
             ds.Tables.Add(listObjCompany[0]);
             frmreport.PayHeadReport(ds);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("PHR:7 " + ex.Message, "Open Miracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// Function to Print
 /// </summary>
 /// <param name="decDeliveryNoteMasterId"></param>
 public void Print(decimal decDeliveryNoteMasterId)
 {
     try
     {
         DeliveryNoteMasterInfo infoDeliveryNoteMaster = new DeliveryNoteMasterInfo();
         //DeliveryNoteMasterSP spDeliveryNoteMaster = new DeliveryNoteMasterSP();
         DeliveryNoteBll bllDeliveryNote = new DeliveryNoteBll();
         DataSet dsDeliveryNote = bllDeliveryNote.DeliveryNotePrinting(decDeliveryNoteMasterId, 1, infoDeliveryNoteMaster.OrderMasterId, infoDeliveryNoteMaster.QuotationMasterId);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.DeliveryNotePrinting(dsDeliveryNote);
     }
     catch (Exception ex)
     {
         MessageBox.Show("DN40:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// Function for Print
 /// </summary>
 /// <param name="fromDate"></param>
 /// <param name="todate"></param>
 public void Print(DateTime fromDate, DateTime todate)
 {
     try
     {
         FinancialStatementBll bllFinancialStatement = new FinancialStatementBll();
         DataSet dsTrail = getdataset();
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.TrailBalanceReportPrinting(dsTrail);
     }
     catch (Exception ex)
     {
         MessageBox.Show("TB:5" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 6
0
 /// <summary>
 /// On print button click
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         DateTime FromDate = this.dtpFromDate.Value;
         DateTime ToDate = this.dtpToDate.Value;
         DataSet ds = new DataSet();
         CompanySP spcompany = new CompanySP();
         DataTable dtblProduct = dtbl.Copy();
         DataTable dtblCompany = spcompany.CompanyViewDataTable(1);
         if (dgvProductBatch.Rows.Count > 0)
         {
             DataTable dtblNew = dtbl.Copy();
             ds.Tables.Add(dtblCompany);
             ds.Tables.Add(dtblProduct);
             frmReport frmReport = new frmReport();
             frmReport.MdiParent = formMDI.MDIObj;
             frmReport.ProductBatchReportPrinting(ds);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show(" PVSBR:9" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 7
0
        /// <summary>
        /// On 'Print' button click to print the data
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void btnPrint_Click(object sender, EventArgs e)
        {
            try
            {
                if (dgvPurchaseReturnReport.Rows.Count > 0)
                {
                    if (dgvPurchaseReturnReport.Rows.Count > 0)
                    {
                        DataSet dsPurchaseReturnReport = new DataSet();
                        CompanySP spCompany = new CompanySP();
                        DataTable dtblGrid = dtblReg.Copy();
                        DataTable dtblCompany = spCompany.CompanyViewDataTable(1);
                        dsPurchaseReturnReport.Tables.Add(dtblGrid);
                        dsPurchaseReturnReport.Tables.Add(dtblCompany);
                        frmReport frmReport = new frmReport();
                        frmReport.MdiParent = formMDI.MDIObj;
                        frmReport.PurchaseReturnReportPrinting(dsPurchaseReturnReport, txtTotalAmount.Text);
                    }
                }
                else
                {
                    Messages.InformationMessage("No data found");
                }
           
            }
            catch (Exception ex)
            {

                MessageBox.Show("PRRT:13" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
         
            }
            
        }
Ejemplo n.º 8
0
 /// <summary>
 /// Print function in crystal report
 /// </summary>
 /// <param name="decSalesMasterId"></param>
 public void Print(decimal decSalesMasterId)
 {
     SalesMasterSP spSalesMaster = new SalesMasterSP();
     SalesMasterInfo InfoSalesMaster = new SalesMasterInfo();
     try
     {
         DataSet dsSalesInvoice = spSalesMaster.salesInvoicePrintAfterSave(decSalesMasterId, 1, InfoSalesMaster.OrderMasterId, InfoSalesMaster.DeliveryNoteMasterId, InfoSalesMaster.QuotationMasterId);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.SalesInvoicePrinting(dsSalesInvoice);
     }
     catch (Exception ex)
     {
         MessageBox.Show("SI: 73" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// On 'Print' button click
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvContraReport.RowCount > 0)
         {
             DataSet ds = new DataSet();
             //CompanySP spCompany = new CompanySP();
             CompanyCreationBll bllCompanyCreation = new CompanyCreationBll();
             frmReport reportobj = new frmReport();
             //ContraMasterSP spContraMaster = new ContraMasterSP();
             ContraVoucherDetailsBll bllContraVoucherDetails = new ContraVoucherDetailsBll();
             List<DataTable> listObjCompany = bllCompanyCreation.CompanyViewDataTable(1);
             List<DataTable> listObjCotraReport = bllContraVoucherDetails.ContraReport(Convert.ToDateTime(dtpFromDate.Value.ToString()), Convert.ToDateTime(dtpToDate.Value.ToString()), cmbVoucherType.Text, cmbCashOrBank.Text, strType);
             ds.Tables.Add(listObjCompany[0]);
             ds.Tables.Add(listObjCotraReport[0]);
             reportobj.MdiParent = formMDI.MDIObj;
             reportobj.ContraVoucherReport(ds);
         }
         else
         {
             MessageBox.Show("No data found", "Open Miracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("CRT:12" + ex.Message, "Open Miracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// Print button click, to print the selected details
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     decimal decVoucherTypeId = 0;
     try
     {
         string strDeliveryMode = cmbDeliveryMode.Text;
         string strInvoiceNo = cmbOrderNo.Text;
         //DeliveryNoteMasterSP spDeliveryNoteMaster = new DeliveryNoteMasterSP();
         DeliveryNoteBll bllDeliveryNote = new DeliveryNoteBll();
         if (dgvDeliveryNoteReport.RowCount > 0)
         {
             if (cmbVoucherType.Text == "All")
             {
                 decVoucherTypeId = 0;
             }
             else
             {
                 decVoucherTypeId = Convert.ToDecimal(cmbVoucherType.SelectedValue.ToString());
             }
             DataSet dsDeliveryNoteReport = bllDeliveryNote.DeliveryNoteReportPrinting(1, Convert.ToDecimal(cmbCashOrParty.SelectedValue.ToString()), decVoucherTypeId, this.dtpFromDate.Value, this.dtpToDate.Value, cmbStatus.Text, strDeliveryMode, strInvoiceNo);
             frmReport frmReport = new frmReport();
             frmReport.MdiParent = formMDI.MDIObj;
             frmReport.DeliveryNoteReportPrinting(dsDeliveryNoteReport);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("DNREP10:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// On 'Print' button click
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvDailyAttendanceReport.RowCount > 0)
         {
             DataSet ds = new DataSet();
             //CompanySP spCompany = new CompanySP();
             CompanyCreationBll bllCompanyCreation = new CompanyCreationBll();
             List<DataTable> listObjCompany = bllCompanyCreation.CompanyViewDataTable(1);
             ds.Tables.Add(listObjCompany[0]);
             AttendanceBll BllAttendanceMaster = new AttendanceBll();
            List<DataTable> ListAttendance = BllAttendanceMaster.DailyAttendanceViewForDailyAttendanceReport(dtpDate.Text.Trim(), cmbStatus.Text.Trim(), cmbEmployee.Text.Trim(), cmbDesignation.Text.Trim());
            ds.Tables.Add(ListAttendance[0]);
             frmReport frmReportObj = new frmReport();
             frmReportObj.MdiParent = formMDI.MDIObj;
             frmReportObj.DailyAttendanceReportPrinting(ds);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("DAR:8" + ex.Message, "Open Miracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 12
0
 /// <summary>
 /// On 'Print' button click
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvBonusDeductionReport.RowCount > 0)
         {
             DataSet ds = new DataSet();
             CompanySP spCompany = new CompanySP();
             DataTable dtblCompany = spCompany.CompanyViewDataTable(1);
             ds.Tables.Add(dtblCompany);
             BonusDedutionSP spBonusDeduction = new BonusDedutionSP();
             DataTable dtblBonusDeduction = spBonusDeduction.BonusDeductionReportGridFill(dtpFromDate.Text, dtpToDate.Text, dtpSalaryMonth.Text, cmbDesignation.Text, cmbEmployee.Text, strBonusOrDeduction);
             ds.Tables.Add(dtblBonusDeduction);
             frmReport frmReportObj = new frmReport();
             frmReportObj.MdiParent = formMDI.MDIObj;
             frmReportObj.BonusDeductionReportPrinting(ds);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("BDR:8" + ex.Message, "Open Miracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// Print function
 /// </summary>
 /// <param name="decMasterId"></param>
 public void Print(decimal decMasterId)
 {
     try
     {
         PurchaseOrderBll BllPurchaseOrder = new PurchaseOrderBll();
         DataSet dsPurchaseOrder = BllPurchaseOrder.PurchaseOrderPrinting(decMasterId);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.PurchaseOrderPrinting(dsPurchaseOrder);
     }
     catch (Exception ex)
     {
         MessageBox.Show("PO14:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 14
0
 /// <summary>
 /// On 'Print' button click for print
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvMonthlySalary.Rows.Count > 0)
         {
             DataSet ds = new DataSet();
             CompanySP spCompany = new CompanySP();
             DataTable dtblCompany = spCompany.CompanyViewDataTable(1);
             ds.Tables.Add(dtblCompany);
             MonthlySalarySP spMonthlySalary = new MonthlySalarySP();
             DataTable dtblMonthlySalary = spMonthlySalary.MonthlySalryViewAllForMonthlySalaryReports(Convert.ToDateTime(dtpFromDate.Value.ToString()), Convert.ToDateTime(dtpToDate.Value.ToString()), cmbDesignation.Text, cmbEmployeeCode.Text, Convert.ToDateTime(dtpSalaryMonth.Value.ToString()));
             ds.Tables.Add(dtblMonthlySalary);
             frmReport frmReportObj = new frmReport();
             frmReportObj.MdiParent = formMDI.MDIObj;
             frmReportObj.MonthlySalaryReportPrinting(ds);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("MSR:9" + ex.Message, "Open Miracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// Function for Print
 /// </summary>
 /// <param name="fromDate"></param>
 /// <param name="toDate"></param>
 public void Print(DateTime fromDate, DateTime toDate)
 {
     try
     {
         DataSet dsProfit = GetDataSet();
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.ProfitAndLossReportPrinting(dsProfit);
     }
     catch (Exception ex)
     {
         MessageBox.Show("PAL :04" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// Print function
 /// </summary>
 /// <param name="decMasterId"></param>
 public void Print(decimal decMasterId)
 {
     try
     {
         DataSet dsPdcReceivable = new DataSet();
         PDCRecivebleBll BllPdcRecieveble = new PDCRecivebleBll();
         dsPdcReceivable = BllPdcRecieveble.PDCReceivableVoucherPrinting(decMasterId, 1);
         frmReport frmreport = new frmReport();
         frmreport.MdiParent = formMDI.MDIObj;
         frmreport.PDCreceivableVoucherPrinting(dsPdcReceivable);
     }
     catch (Exception ex)
     {
         MessageBox.Show("PR21:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 17
0
        /// <summary>
        /// Function to print the voucher
        /// </summary>
        /// <param name="decMasterId"></param>
        public void Print(decimal decMasterId)
        {
            try
            {
                JournalMasterSP SpJournalMaster = new JournalMasterSP();
                DataSet dsJournalVoucher = SpJournalMaster.JournalVoucherPrinting(decMasterId, 1);
                frmReport frmReport = new frmReport();
                frmReport.MdiParent = formMDI.MDIObj;
                frmReport.JournalVoucherPrinting(dsJournalVoucher);
            }
            catch (Exception ex)
            {
                MessageBox.Show("JV27:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }


        }
Ejemplo n.º 18
0
 /// <summary>
 /// On print button click
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (rbtnInput.Checked)
         {
             isInput = true;
         }
         else
         {
             isInput = false;
         }
         if (rbtnBillwise.Checked)
         {
             isBillwise = true;
         }
         else
         {
             isBillwise = false;
         }
         TaxBll bllTax = new TaxBll();
         DataSet dsTaxReport = new DataSet();
         DateTime dtFromDate = DateTime.Parse(txtFromDate.Text);
         DateTime dtToDate = DateTime.Parse(txtToDate.Text);
         decimal dectaxId = Convert.ToDecimal(cmbTax.SelectedValue.ToString());
         decimal decvoucherTypeId = Convert.ToDecimal(cmbVoucherType.SelectedValue.ToString());
         if (isBillwise)
         {
             dsTaxReport = bllTax.TaxCrystalReportGridFillByBillWise(1, dtFromDate, dtToDate, dectaxId, decvoucherTypeId, isInput);
         }
         else
         {
             dsTaxReport = bllTax.TaxCrystalReportGridFillByProductwise(1, dtFromDate, dtToDate, dectaxId, decvoucherTypeId, isInput);
         }
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         if (dgvTaxReport.Rows.Count > 0)
         {
             frmReport.TaxCrystalReportPrint(dsTaxReport, isBillwise);
         }
         else
         {
             Messages.InformationMessage("No Data Found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("TR:16" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// print button click, call the print function
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (DGVClraranceReport.RowCount > 0)
         {
             PDCClearanceBll BllPDCClearance = new PDCClearanceBll();
             DataSet dsPDCClearance = new DataSet();
             dsPDCClearance = BllPDCClearance.PDCClearanceReportPrinting(Convert.ToDateTime(dtpFrmDate.Value.ToString()), Convert.ToDateTime(dtpToDate.Value.ToString()), cmbAccountLedger.Text.ToString(), cmbVoucherType.Text.ToString(), txtVoucherNo.Text.ToString(), 1);
             frmReport frmreport = new frmReport();
             frmreport.MdiParent = formMDI.MDIObj;
             frmreport.PDCClearanceReportPrinting(dsPDCClearance);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("PCREP12:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 20
0
 /// <summary>
 /// Function to print the DayBook
 /// </summary>
 /// <param name="fromDate"></param>
 /// <param name="toDate"></param>
 /// <param name="decVoucherTypeId"></param>
 /// <param name="decLedgerId"></param>
 /// <param name="blCondenced"></param>
 public void Print(DateTime fromDate, DateTime toDate, decimal decVoucherTypeId, decimal decLedgerId, bool blCondenced)
 {
     try
     {
         DataSet dsDayBookReport = getdataset();
         DataSet dsDayBookReportCondensed = getdatasetCondensed();
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         if (rbtnCondensed.Checked == true)
         {
             frmReport.dayBookReportPrintingCondensed(dsDayBookReportCondensed);
         }
         else
         {
             frmReport.dayBookReportPrintingDetailed(dsDayBookReport);
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("DB8:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 21
0
 /// <summary>
 /// On 'Print' button click to print
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvSalaryPackage.RowCount > 0)
         {
             frmReport frmreport = new frmReport();
             DataSet ds = new DataSet();
             SalaryPackageSP spSalaryPackage = new SalaryPackageSP();
             CompanySP spCompany = new CompanySP();
             DataTable dtblSalaryPackage = spSalaryPackage.SalaryPackageViewAllForSalaryPackageReport(cmbPackageName.Text, cmbStatus.Text);
             DataTable dtblCompany = spCompany.CompanyViewDataTable(1);
             ds.Tables.Add(dtblSalaryPackage);
             ds.Tables.Add(dtblCompany);
             frmreport.MdiParent = formMDI.MDIObj;
             frmreport.SalaryPackageReport(ds);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("SPD:9 " + ex.Message, "Open Miracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 22
0
 /// <summary>
 /// Print button click
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvMaterialReceiptReport.RowCount > 0)
         {
             MaterialReceiptMasterSP spMaterialReceiptMaster = new MaterialReceiptMasterSP();
             DataSet dsMaterialReceiptReport = spMaterialReceiptMaster.MaterialReceiptReportPrinting(1, strInvoiceNo, strStatus, decLedgerId, strproductCode, decVoucherTypeId, this.dtpFromDate.Value, this.dtpToDate.Value, decOrderId);
             frmReport frmReport = new frmReport();
             frmReport.MdiParent = formMDI.MDIObj;
             frmReport.MaterialReceiptReportPrinting(dsMaterialReceiptReport);
         }
         else
         {
             Messages.InformationMessage("No data found");
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("MRR15:" + 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());
                    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>
 /// Function to print the report
 /// </summary>
 /// <param name="decledgerId"></param>
 /// <param name="strAccountGroup"></param>
 /// <param name="dtfromdate"></param>
 /// <param name="dttodate"></param>
 public void print(decimal decledgerId, string strAccountGroup, DateTime dtfromdate, DateTime dttodate)
 {
     try
     {
         DataSet dsoutstanding = BllPartyBalance.OutstandingPrint(decledgerId, strAccountGroup, dtfromdate, dttodate, 1);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.OutstandingPrinting(dsoutstanding);
     }
     catch (Exception ex)
     {
         MessageBox.Show("OR:08" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 25
0
 /// <summary>
 /// Print function
 /// </summary>
 /// <param name="decPaymentMasterId"></param>
 public void Print(decimal decPaymentMasterId)
 {
     try
     {
         PaymentMasterSP SpPaymentMaster = new PaymentMasterSP();
         DataSet dsPaymentVoucher = SpPaymentMaster.PaymentVoucherPrinting(decPaymentMasterId, 1);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.PaymentVoucherPrinting(dsPaymentVoucher);
     }
     catch (Exception ex)
     {
         MessageBox.Show("PV10:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 26
0
 /// <summary>
 /// Function to print stock journal
 /// </summary>
 /// <param name="decMasterId"></param>
 public void Print(decimal decMasterId)
 {
     StockJournalMasterSP spStockJournalMaster = new StockJournalMasterSP();
     try
     {
         DataSet dsStockJournal = spStockJournalMaster.StockJournalPrinting(decMasterId);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.StockJournalPrinting(dsStockJournal);
     }
     catch (Exception ex)
     {
         MessageBox.Show("SJ: 53" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
        /// <summary>
        /// Function toprint
        /// </summary>
        public void ReportPrint()
        {
            try
            {
                
                RejectionOutBll bllRejectionOut = new RejectionOutBll();
                decimal decMaterialReceiptNo = 0;
                if (cmbMaterialReceiptNo.SelectedIndex != -1)
                {
                    decMaterialReceiptNo = Convert.ToDecimal(cmbMaterialReceiptNo.SelectedValue.ToString());
                }
                strVoucherNo = txtVoucherNo.Text;
                strProductCode = txtProductCode.Text;
                DataSet dsRejectionOut = bllRejectionOut.RejectionOutReportPrinting(decmaterialReceiptMasterId, 1, Convert.ToDateTime(txtFromDate.Text), Convert.ToDateTime(txtToDate.Text), Convert.ToDecimal(cmbVoucherType.SelectedValue.ToString()), strVoucherNo, Convert.ToDecimal(cmbCashOrParty.SelectedValue.ToString()), strProductCode, strProductName);
                frmReport frmReport = new frmReport();
                frmReport.MdiParent = formMDI.MDIObj;
                frmReport.RejectionOutReportPrinting(dsRejectionOut);
            }
            catch (Exception ex)
            {
                MessageBox.Show("RORP03:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }

        }
 /// <summary>
 /// Function to print the report
 /// </summary>
 /// <param name="toDate"></param>
 public void Print1(DateTime toDate)
 {
     try
     {
         FinancialStatementBll bllFinancialStatement = new FinancialStatementBll();
         DataSet destBalance = getdataset1();
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.AgeingReportPrint1(destBalance);
     }
     catch (Exception ex)
     {
         MessageBox.Show("AR9:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// Its for using Crystal report printing
 /// </summary>
 /// <param name="decContraMasterId"></param>
 public void Print(decimal decContraMasterId)
 {
     try
     {
         //ContraMasterSP spContraMaster = new ContraMasterSP();
         ContraVoucherDetailsBll bllContraVoucherDetails = new ContraVoucherDetailsBll();
         DataSet dsContraVoucher = bllContraVoucherDetails.ContraVoucherPrinting(decContraMasterId, 1);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.ContraVoucherPrinting(dsContraVoucher);
     }
     catch (Exception ex)
     {
         MessageBox.Show("CV:26" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 public void Print(decimal decServiceMasterId, decimal decExchangeRateId)
 {
     try
     {
         ServicesBll BllService = new ServicesBll();
         DataSet dsServiceVoucher = BllService.ServiceVoucherPrinting(decServiceMasterId, 1, decExchangeRateId);
         frmReport frmReport = new frmReport();
         frmReport.MdiParent = formMDI.MDIObj;
         frmReport.ServiceVoucherPrinting(dsServiceVoucher);
     }
     catch (Exception ex)
     {
         MessageBox.Show("SV 25 : " + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Ejemplo n.º 31
0
 /// <summary>
 /// On print button click
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         frmReport crptReport  = new frmReport();
         DataSet   ds          = new DataSet();
         DataTable dtblFormat2 = new DataTable();
         DataTable dtblTotal   = new DataTable();
         CompanySP spCompany   = new CompanySP();
         DataTable dtblCompany = new DataTable();
         dtblCompany = spCompany.CompanyViewAll();
         if (dgvVatreturn.Rows.Count > 0)
         {
             if (dtblFill.Rows.Count > 0)
             {
                 DataTable dtblReportFill = new DataTable();
                 dtblReportFill.Columns.Add("SlNO");
                 dtblReportFill.Columns.Add("Invoice No");
                 dtblReportFill.Columns.Add("Date");
                 dtblReportFill.Columns.Add("Party Name");
                 dtblReportFill.Columns.Add("Mailing Name");
                 dtblReportFill.Columns.Add("Tin No");
                 dtblReportFill.Columns.Add("qt");
                 dtblReportFill.Columns.Add("Sales Amound");
                 dtblReportFill.Columns.Add("Tax Amount");
                 dtblReportFill.Columns.Add("Cess");
                 dtblReportFill.Columns.Add("Net Amount");
                 dtblReportFill.Columns.Add("billDiscount");
                 dtblReportFill.Columns.Add("grandtotal");
                 for (int i = 0; i < dgvVatreturn.Rows.Count; i++)
                 {
                     DataRow drow = dtblReportFill.NewRow();
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtSlno"].Value != null)
                     {
                         drow["SlNO"] = dgvVatreturn.Rows[i].Cells["dgvtxtSlno"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtInvoiceNo"].Value != null)
                     {
                         drow["Invoice No"] = dgvVatreturn.Rows[i].Cells["dgvtxtInvoiceNo"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtDate"].Value != null)
                     {
                         drow["Date"] = dgvVatreturn.Rows[i].Cells["dgvtxtDate"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtPartyName"].Value != null)
                     {
                         drow["Party Name"] = dgvVatreturn.Rows[i].Cells["dgvtxtPartyName"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtMailingName"].Value.ToString() != string.Empty)
                     {
                         drow["Mailing Name"] = dgvVatreturn.Rows[i].Cells["dgvtxtMailingName"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtTinNo"].Value != null)
                     {
                         drow["Tin No"] = dgvVatreturn.Rows[i].Cells["dgvtxtTinNo"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtQty"].Value != null)
                     {
                         drow["qt"] = dgvVatreturn.Rows[i].Cells["dgvtxtQty"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtSalesAmount"].Value != null)
                     {
                         drow["Sales Amound"] = dgvVatreturn.Rows[i].Cells["dgvtxtSalesAmount"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtTaxAmount"].Value != null)
                     {
                         drow["Tax Amount"] = dgvVatreturn.Rows[i].Cells["dgvtxtTaxAmount"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtCess"].Value != null)
                     {
                         drow["Cess"] = dgvVatreturn.Rows[i].Cells["dgvtxtCess"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtNetAmount"].Value != null)
                     {
                         drow["Net Amount"] = dgvVatreturn.Rows[i].Cells["dgvtxtNetAmount"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtbillDiscount"].Value != null)
                     {
                         drow["billDiscount"] = dgvVatreturn.Rows[i].Cells["dgvtxtbillDiscount"].Value.ToString();
                     }
                     if (dgvVatreturn.Rows[i].Cells["dgvtxtGrandTotal"].Value != null)
                     {
                         drow["grandtotal"] = dgvVatreturn.Rows[i].Cells["dgvtxtGrandTotal"].Value.ToString();
                     }
                     dtblReportFill.Rows.Add(drow);
                 }
                 ds.Tables.Add(dtblReportFill);
                 ds.Tables.Add(dtblCompany);
                 crptReport.vatreturnReport(ds);
             }
             else
             {
                 VoucherTypeSP spVoucher = new VoucherTypeSP();
                 dtblFormat2 = spVoucher.VatGridFill(DateTime.Parse(dtpFrmDate.Text), DateTime.Parse(dtpToDate.Text), cmbTypeofVoucher.Text, Convert.ToDecimal(cmbVouchertype.SelectedValue.ToString()), strformat, cmbTax.Text);
                 if (dgvVatreturn.Rows.Count > 1)
                 {
                     dtblTotal.Columns.Add("taxableamt");
                     dtblTotal.Columns.Add("taxAmount");
                     DataRow dr1 = dtblTotal.NewRow();
                     dr1["taxableamt"] = dgvVatreturn.Rows[dgvVatreturn.Rows.Count - 2].Cells["dgvtxtTaxableAmount"].Value.ToString();
                     dr1["taxAmount"]  = dgvVatreturn.Rows[dgvVatreturn.Rows.Count - 2].Cells["dgvtxttax"].Value.ToString();
                     dtblTotal.Rows.Add(dr1);
                     ds.Tables.Add(dtblCompany);
                     ds.Tables.Add(dtblFormat2);
                     ds.Tables.Add(dtblTotal);
                     crptReport.vatreturnReportFormat(ds);
                 }
             }
         }
         else
         {
             MessageBox.Show("No data found", "Openmiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
         }
     }
     catch (Exception ex)
     {
         formMDI.infoError.ErrorString = "VRR15:" + ex.Message;
     }
 }