private void GenerateReport() { ReportBLL cls = new ReportBLL(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "CntrStockSummery", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "CntrStockSummery.rdlc"; DataSet ds = EMS.BLL.LogisticReportBLL.GetRptCntrStockSummery(ddlLine.SelectedValue, ddlLoc.SelectedValue, txtdtStock.Text.Trim()); try { rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.SetParameters(new ReportParameter("StockDate", txtdtStock.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("loc", ddlLoc.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("line", ddlLine.SelectedItem.Text)); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("DataSet3", ds.Tables[0])); rptViewer.LocalReport.Refresh(); } catch { } }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "MoneyReciept", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "MoneyReciept.rdlc"; //string invoiceNo = ((TextBox)AutoCompletepInvoice1.FindControl("txtInvoice")).Text; DataSet ds = EMS.BLL.BLLReport.GetMoneyRcptDetails(_MoneyRecptNo); try { rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.ZoomPercent = 150; rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("DataSet3", ds.Tables[0])); rptViewer.LocalReport.Refresh(); } catch { } }
private void GenerateReport() { LocalReportManager reportManager = new LocalReportManager(rptViewer, "ExpManifestEdge", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "ExpManifestEdge.rdlc"; string rptSelect = "F"; if (ddlCargoOrFreight.SelectedIndex == 2) { rptSelect = "C"; _reportName = "CARGO MANIFEST - (" + ddlLocation.SelectedItem + ")"; } else { _reportName = "FREIGHT MANIFEST - (" + ddlLocation.SelectedItem + ")"; } var main = ReportBLL.GetRptFrieghtManifest(ddlBLNo.SelectedValue); var TFS = ReportBLL.GetRptFrieghtManifest_TFS(ddlBLNo.SelectedValue); var CTRS = ReportBLL.GetRptFrieghtManifest_CTRS(ddlBLNo.SelectedValue); rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsLin", main.Tables[0])); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsTFS", TFS.Tables[0])); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsCTRS", CTRS.Tables[0])); rptViewer.LocalReport.SetParameters(new ReportParameter("EXPBLID", ddlBLNo.SelectedValue)); rptViewer.LocalReport.SetParameters(new ReportParameter("ReportName", _reportName)); rptViewer.LocalReport.SetParameters(new ReportParameter("FreightOrCargo", rptSelect)); rptViewer.LocalReport.Refresh(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); ICallDetail callDetail = new CallDetailEntity(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "CustomerListWithLoc", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "CustomerListWithLoc.rdlc"; BuildEntity(callDetail); IEnumerable <ICallDetail> lst = cls.GetCustomerListWithLoc(callDetail, _userId); rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.DataSources.Add(new ReportDataSource("ReportDataSet", lst)); rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); if (txtArea.Text != ResourceManager.GetStringWithoutName("ERR00016")) { rptViewer.LocalReport.SetParameters(new ReportParameter("AreaName", txtArea.Text)); } else { rptViewer.LocalReport.SetParameters(new ReportParameter("AreaName", txtArea.Text)); } rptViewer.LocalReport.SetParameters(new ReportParameter("Location", ddlLoc.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("SalesPerson", ddlSales.SelectedItem.Text)); rptViewer.LocalReport.Refresh(); }
private void GenerateSummaryReport() { ReportBLL cls = new ReportBLL(); string rptName = ""; if (chkDetails.Checked == true) { rptName = "CashierWiseSaleDetail"; } else { rptName = "CashierWiseSaleSummary"; } LocalReportManager reportManager = new LocalReportManager(rptViewer, rptName, ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); ReportCriteria criteria = new ReportCriteria(); BuildCriteria(criteria); List <ReportEntity> lstData = ReportBLL.GetCashierWiseSale(criteria); ReportDataSource dsGeneral = new ReportDataSource("dsReportData", lstData); reportManager.AddParameter("FromDate", txtFromDt.Text.Trim()); reportManager.AddParameter("ToDate", txtToDt.Text.Trim()); reportManager.AddDataSource(dsGeneral); reportManager.Show(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); string agentName = string.Empty; int vesselId = Convert.ToInt32(hdnVessel.Value); //Int64 vesselId = GetSelectedVesselId(); Int64 voyageId = Convert.ToInt64(ddlVoyage.SelectedValue); List <ExportEDIEntity> lstHeader = ReportBLL.GetExportEdi(vesselId, voyageId, Convert.ToInt32(ddlPort.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue)); List <ExportEDIEntity> lstData = ReportBLL.GetExportEdiCntr(vesselId, voyageId, Convert.ToInt32(ddlPort.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue)); DataSet dsCompany = CommonBLL.GetCompanyDetails(1); if (!ReferenceEquals(dsCompany, null) && dsCompany.Tables.Count > 0 && dsCompany.Tables[0].Rows.Count > 0) { agentName = Convert.ToString(dsCompany.Tables[0].Rows[0]["CompName"]); } LocalReportManager reportManager = new LocalReportManager(rptViewer, "ExportEDI", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); reportManager.HasSubReport = true; reportManager.AddParameter("VesselVoyage", txtVessel.Text.Trim() + " V." + ddlVoyage.SelectedItem.Text); reportManager.AddParameter("AgentName", agentName); reportManager.AddParameter("MainLineOperator", txtMLO.Text.Trim()); reportManager.AddDataSource(new ReportDataSource("DataSetHeader", lstHeader)); reportManager.AddSubReportDataSource(new ReportDataSource("DataSetContainer", lstData)); reportManager.Show(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); ICallDetail callDetail = new CallDetailEntity(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "DailyCallRpt", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "DailyCallRpt.Rdlc"; DateTime fromDate; DateTime toDate; fromDate = Convert.ToDateTime(txtFromDt.Text, _culture); toDate = Convert.ToDateTime(txtToDt.Text, _culture); BuildEntity(callDetail); IEnumerable <ICallDetail> lst = cls.GetDailyCallData(fromDate, toDate, callDetail, _userId); rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; //rptViewer.LocalReport.ReportPath = Server.MapPath("/" + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("ReportDataSet", lst)); rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.SetParameters(new ReportParameter("FromDate", txtFromDt.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("ToDate", txtToDt.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("Location", ddlLoc.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("SalesPerson", ddlSales.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("Prospect", ddlPros.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("CallType", ddlType.SelectedItem.Text)); rptViewer.LocalReport.Refresh(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); Int64 vesselId = GetSelectedVesselId(); string VesselName = GetSelectedVesselName(); //Int64 voyageId = GetSelectedVoyageId(); Int64 voyageId = Convert.ToInt64(ddlVoyage.SelectedValue); List <ImpRegisterEntity> lstHeader = ReportBLL.GetImportRegisterHeader(Convert.ToInt32(ddlLine.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue), voyageId, vesselId); List <ImpRegisterEntity> lstFooter = ReportBLL.GetImportRegisterFooter(Convert.ToInt32(ddlLine.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue), voyageId, vesselId); LocalReportManager reportManager = new LocalReportManager(rptViewer, "ImportRegister", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "ImportRegister.rdlc"; rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; //rptViewer.LocalReport.ReportPath = Server.MapPath("/" + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("HeaderDataSet", lstHeader)); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("FooterDataSet", lstFooter)); rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.SetParameters(new ReportParameter("Location", ddlLoc.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("Line", ddlLine.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("Vessel", VesselName)); rptViewer.LocalReport.SetParameters(new ReportParameter("Voyage", ddlVoyage.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("ReportType", string.Empty)); rptViewer.LocalReport.Refresh(); ddlVoyage.SelectedValue = "0"; }
private void GenerateReport(Int64 doId) { LocalReportManager reportManager = new LocalReportManager("DeliveryOrder", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); ReportBLL cls = new ReportBLL(); List <DOPrintEntity> lstDO = ReportBLL.GetDeliveryOrder(doId); List <DOPrintEntity> lstDOCntr = ReportBLL.GetDeliveryOrderContainer(doId); ReportDataSource dsDO = new ReportDataSource("dsDeliveryOrder", lstDO); ReportDataSource dsDOCntr = new ReportDataSource("dsDeliveryOrderContainer", lstDOCntr); reportManager.ReportFormat = ReportFormat.PDF; reportManager.AddDataSource(dsDO); reportManager.AddDataSource(dsDOCntr); reportManager.Export(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "CashierLog", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); ReportCriteria criteria = new ReportCriteria(); //BuildCriteria(criteria); List <ReportEntity> lstData = ReportBLL.GetCashierLog(criteria); ReportDataSource dsGeneral = new ReportDataSource("dsReportData", lstData); reportManager.AddParameter("FromDate", txtFromDt.Text.Trim()); reportManager.AddParameter("ToDate", txtToDt.Text.Trim()); reportManager.AddDataSource(dsGeneral); reportManager.Show(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "CntrWiseStock", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "CntrWiseStock.rdlc"; //DataSet ds = EMS.BLL.LogisticReportBLL.GetRptCntrStockDetails(ddlLine.SelectedValue, ddlLoc.SelectedValue, ddlStatus.SelectedValue, ddlContainerType.SelectedValue, txtdtStock.Text.Trim()); IList <ContainerWiseStockEntity> ContainersStatus = EMS.BLL.LogisticReportBLL.GetRptContainerwiseStockSummery(txtContainerNo.Text, Convert.ToInt32(ddlLine.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue)); try { string Size = string.Empty; string LStatus = string.Empty; string lLocation = string.Empty; var maxDate = ContainersStatus.Max(x => x.MovementDate); IEnumerable <ContainerWiseStockEntity> Items = from itm in ContainersStatus where itm.MovementDate == maxDate select itm; Size = Items.ToList()[0].Size; LStatus = Items.ToList()[0].MoveAbbr; lLocation = Items.ToList()[0].Locabbr; rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.SetParameters(new ReportParameter("CntNo", txtContainerNo.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("CntSize", Size)); rptViewer.LocalReport.SetParameters(new ReportParameter("LastStatus", LStatus)); rptViewer.LocalReport.SetParameters(new ReportParameter("LastLocation", lLocation)); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("ContainerWiseStock", ContainersStatus)); rptViewer.LocalReport.Refresh(); } catch (Exception ex) { string s = ex.Message; } }
private void GenerateReportM() { LocalReportManager reportManager = new LocalReportManager(rptViewer, "MME", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "MME.rdlc"; string rptSelect = "F"; var main = ReportBLL.GetBlNumberFromVoyageID(Convert.ToInt32(ddlVoyage.SelectedValue), Convert.ToInt32(ddlVessel.SelectedValue), Convert.ToInt32(ddlPOD.SelectedValue), Convert.ToInt32(ddlLocation.SelectedValue), Convert.ToInt32(ddlLine.SelectedValue)); if (ddlCargoOrFreight.SelectedIndex == 2) { rptSelect = "C"; _reportName = "CARGO MANIFEST - (" + ddlLocation.SelectedItem + ")"; } else { _reportName = "FREIGHT MANIFEST - (" + ddlLocation.SelectedItem + ")"; } rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsVoyage", main.Tables[0])); rptViewer.LocalReport.SetParameters(new ReportParameter("ReportName", _reportName)); rptViewer.LocalReport.SetParameters(new ReportParameter("FreightOrCargo", rptSelect)); rptViewer.LocalReport.SubreportProcessing += new SubreportProcessingEventHandler(SubreportEventHandler); rptViewer.LocalReport.Refresh(); //LocalReportManager reportManager = new LocalReportManager(rptViewer, "MME", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); //string rptName = "MME.rdlc"; //var main = ReportBLL.GetBlNumberFromVoyageID(Convert.ToInt64(ddlVoyage.SelectedValue)); //_reportName = "ReportName"; //rptViewer.Reset(); //rptViewer.LocalReport.Dispose(); //rptViewer.LocalReport.DataSources.Clear(); //rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; //rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsVoyage", main.Tables[0])); //rptViewer.LocalReport.SetParameters(new ReportParameter("ReportName", _reportName)); ////rptViewer.LocalReport.SetParameters(new ReportParameter("RptHeader", "FREIGHT MANIFEST - (" + ddlLocation.SelectedItem + ")")); //rptViewer.LocalReport.SubreportProcessing += new SubreportProcessingEventHandler(SubreportEventHandler); //rptViewer.LocalReport.Refresh(); }
private void GenerateReport() { LocalReportManager reportManager = new LocalReportManager(rptViewer, "ExpManifestEdge", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "ExpManifestEdge.rdlc"; var main = ReportBLL.GetRptFrieghtManifest(ddlBlNo.SelectedValue); var TFS = ReportBLL.GetRptFrieghtManifest_TFS(ddlBlNo.SelectedValue); var CTRS = ReportBLL.GetRptFrieghtManifest_CTRS(ddlBlNo.SelectedValue); rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsLin", main.Tables[0])); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsTFS", TFS.Tables[0])); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsCTRS", CTRS.Tables[0])); rptViewer.LocalReport.SetParameters(new ReportParameter("EXPBLID", ddlBlNo.SelectedValue)); rptViewer.LocalReport.Refresh(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); ICallDetail callDetail = new CallDetailEntity(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "MISRptYearly", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "MISRptYearly.rdlc"; BuildEntity(callDetail); IEnumerable <ICallDetail> lst = cls.GetYearlyMisReportData(Convert.ToInt32(ddlYear.SelectedValue), callDetail, Convert.ToChar(ddlParam.SelectedValue), _userId); rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.DataSources.Add(new ReportDataSource("ReportDataSet", lst)); rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.SetParameters(new ReportParameter("Location", ddlLoc.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("ReportType", ddlParam.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("RptYear", ddlYear.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("Prospect", ddlPros.SelectedItem.Text)); rptViewer.LocalReport.Refresh(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); Int64 vesselId = GetSelectedVesselId(); //Int64 voyageId = GetSelectedVoyageId(); Int64 voyageId = Convert.ToInt64(ddlVoyage.SelectedValue); List <ImpBLChkLstEntity> lstEntity = ReportBLL.GetImportBLCheckList(Convert.ToInt32(ddlLine.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue), voyageId, vesselId); LocalReportManager reportManager = new LocalReportManager(rptViewer, "ImpBLChkLst", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "ImpBLChkLst.rdlc"; rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; //rptViewer.LocalReport.ReportPath = Server.MapPath("/" + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("RptDataSet", lstEntity)); rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.SetParameters(new ReportParameter("ReportDate", System.DateTime.Now.ToString("MMMM dd, yyyy"))); rptViewer.LocalReport.Refresh(); ddlVoyage.SelectedValue = "0"; }
private void GenerateReport() { string pod = ((TextBox)AutoCompletepPort1.FindControl("txtPort")).Text; pod = pod.Contains(',') ? pod.Split(',')[1] : ""; if (pod.Trim() == "") { lblError.Attributes.Add("Style", "display:block"); return; } else { lblError.Attributes.Add("Style", "display:none"); } ReportBLL cls = new ReportBLL(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "IGMCargoDesc", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "IGMCargoDesc.rdlc"; int vesselId = Convert.ToInt32(ddlVessel.SelectedValue); int voyageId = ddlVoyage.SelectedIndex > 0 ? Convert.ToInt32(ddlVoyage.SelectedValue) : 0; DBInteraction dbinteract = new DBInteraction(); DataSet ds = EMS.BLL.IGMReportBLL.GetRptCargoDesc(vesselId, voyageId, dbinteract.GetId("Port", pod)); try { rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.SetParameters(new ReportParameter("ReportName", "C A R G O D E C L A R A T I O N")); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("DataSet1", ds.Tables[0])); rptViewer.LocalReport.Refresh(); } catch { } }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); //string stat = ""; //if (ddlStatus.Text == "All") // stat = "A"; //else if (ddlStatus.Text == "Empty") // stat = "E"; //else // stat = "L"; //List<YearlyMISEntity> lstEntity = ReportBLL.GetYearlyMIS(Convert.ToInt32(ddlYear.SelectedValue), Convert.ToInt32(ddlLine.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue), ddlSize.Text, stat); LocalReportManager reportManager = new LocalReportManager(rptViewer, "YearlyMIS", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "YearlyMIS.rdlc"; DataSet ds = EMS.BLL.LogisticReportBLL.GetRptYearlyReport(Convert.ToInt32(ddlYear.SelectedValue), Convert.ToInt32(ddlLine.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue), ddlSize.Text, ddlStatus.Text); //BuildEntity(callDetail); //IEnumerable<ICallDetail> lst = cls.GetYearlyMisReportData(Convert.ToInt32(ddlYear.SelectedValue), callDetail, Convert.ToChar(ddlParam.SelectedValue), _userId); rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; //rptViewer.LocalReport.DataSources.Add(new ReportDataSource("ReportDataSet", lst)); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("ReportDataSet", ds.Tables[0])); rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.SetParameters(new ReportParameter("Location", ddlLoc.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("Prospect", ddlLine.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("RptYear", ddlYear.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("ReportType", ddlStatus.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("Size", ddlSize.SelectedItem.Text)); rptViewer.LocalReport.Refresh(); }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "IGMCargoDesc", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "IGMCargoDesc.rdlc"; int vesselId = Convert.ToInt32(ddlVessel.SelectedValue); int voyageId = ddlVoyage.SelectedIndex > 0 ? Convert.ToInt32(ddlVoyage.SelectedValue) : 0; DataSet ds = EMS.BLL.IGMReportBLL.GetRptCargoDesc(vesselId, voyageId); try { rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + "/" + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.DataSources.Add(new ReportDataSource("DataSet1", ds.Tables[0])); rptViewer.LocalReport.Refresh(); } catch { } }
private void GenerateReport() { ReportBLL cls = new ReportBLL(); DateTime dtFrom = Convert.ToDateTime(txtFromDt.Text, _culture); DateTime dtTo = Convert.ToDateTime(txtToDt.Text, _culture); List <ImpRegisterSummaryEntity> lstReg = ReportBLL.GetImportRegisterSummary(Convert.ToInt32(ddlLine.SelectedValue), Convert.ToInt32(ddlLoc.SelectedValue), dtFrom, dtTo); LocalReportManager reportManager = new LocalReportManager(rptViewer, "ImportSummary", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); string rptName = "ImportSummary.rdlc"; rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; //rptViewer.LocalReport.ReportPath = Server.MapPath("/" + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("ImpRegDataSet", lstReg)); rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]))); rptViewer.LocalReport.SetParameters(new ReportParameter("Location", ddlLoc.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("Line", ddlLine.SelectedItem.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("DischargeFrom", txtFromDt.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("DischargeTo", txtToDt.Text)); rptViewer.LocalReport.Refresh(); }
private void GenerateReport() { lblMsg.Text = ""; ReportBLL cls = new ReportBLL(); LocalReportManager reportManager = new LocalReportManager(rptViewer, "ImpBilling", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); //string rptName = "RptimpBill.rdlc"; //string rptName = "RptImpBillAnnex.rdlc"; string rptName = string.Empty; if (rbRpt.SelectedValue == "1") { rptName = "RptimpBill.rdlc"; string BlRefNo = ((TextBox)autoComplete1.FindControl("txtBlNo")).Text; DataSet ds = EMS.BLL.BLLReport.GetImpBill(hdnBLId.Value, txtdtBill.Text); decimal gamt1 = 0; decimal.TryParse(Convert.ToString(ds.Tables[0].Compute("Sum(col1)", "")), out gamt1); decimal MRamt = 0; decimal.TryParse(Convert.ToString(ds.Tables[0].Compute("Sum(col2)", "")), out MRamt); decimal famt = gamt1 - MRamt; string finalAmt = string.Empty; if (famt > 0) { finalAmt = "Amount to Collect Rs. " + famt; } else if (famt < 0) { finalAmt = "Amount to Refund Rs. " + famt * (-1); } else { finalAmt = "Amount to Refund NIL"; } famt = Math.Abs(famt); string numToWords = EMS.BLL.BLLReport.GetNumToWords(Convert.ToInt64(famt)); try { string compname = Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]); rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", compname)); rptViewer.LocalReport.SetParameters(new ReportParameter("Address", EMS.BLL.BLLReport.GetAddByCompName(compname))); rptViewer.LocalReport.SetParameters(new ReportParameter("tillDate", txtdtBill.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("BL_Ref", txtBlNo.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("finalAmt", finalAmt)); rptViewer.LocalReport.SetParameters(new ReportParameter("NumToWords", numToWords)); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("DataSet1", ds.Tables[0])); rptViewer.LocalReport.Refresh(); } catch (Exception ex) { lblMsg.Text = ex.Message; } lblMsg.Text = rptViewer.LocalReport.ReportPath + "dgfdfgdf"; } else if (rbRpt.SelectedValue == "2") { rptName = "RptImpBillAnnex.rdlc"; string BlRefNo = ((TextBox)autoComplete1.FindControl("txtBlNo")).Text; DataSet ds = EMS.BLL.BLLReport.GetImpBillAnne(hdnBLId.Value, txtdtBill.Text); try { string compname = Convert.ToString(ConfigurationManager.AppSettings["CompanyName"]); rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.SetParameters(new ReportParameter("CompanyName", compname)); rptViewer.LocalReport.SetParameters(new ReportParameter("Address", EMS.BLL.BLLReport.GetAddByCompName(compname))); rptViewer.LocalReport.SetParameters(new ReportParameter("tillDate", txtdtBill.Text)); rptViewer.LocalReport.SetParameters(new ReportParameter("BL_Ref", txtBlNo.Text)); //rptViewer.LocalReport.SetParameters(new ReportParameter("DetentionDays", detentiondays)); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("DataSet1", ds.Tables[0])); rptViewer.LocalReport.Refresh(); } catch (Exception ex) { lblMsg.Text = ex.Message; } } else { return; } }
protected void btnReport_Click(object sender, EventArgs e) { DownLoadPDF(); return; ISearchCriteria iSearchCriteria = new SearchCriteria(); iSearchCriteria.StringParams = new List <string>() { ddlBlNo.SelectedValue //"MUM/UA/13-14/000001" }; /*Report Viewer PDF on aspx*/ // iSearchCriteria = null; // var temp = ExpBLPrintingBLL.GetxpBLPrinting(iSearchCriteria); // Model = temp==null?(List<BLPrintModel>)null:new List<BLPrintModel>() {temp }; var temp = ExpBLPrintingBLL.GetxpBLPrintingDS(iSearchCriteria); DataSet dsBLPrinting = new DataSet(); DataTable dtBLPrintingCons = null; DataTable dtBLPrintingCons5 = null; //int i = 0; if (temp != null && temp.Tables.Count > 0) { //fillFakData(temp.Tables[1]); var top5 = temp.Tables[1].AsEnumerable().Take(5); var Next5 = temp.Tables[1].AsEnumerable().Skip(5); dtBLPrintingCons = temp.Tables[1].Clone(); dtBLPrintingCons5 = temp.Tables[1].Clone(); //foreach (DataRow dr in top5){ // dtBLPrintingCons5.ImportRow(dr); //} //foreach (DataRow dr in Next5){ // dtBLPrintingCons.ImportRow(dr); //} string rptName; LocalReportManager reportManager = new LocalReportManager(rptViewer, "BLPrint", ConfigurationManager.AppSettings["ReportNamespace"].ToString(), ConfigurationManager.AppSettings["ReportPath"].ToString()); if (ddlLine.SelectedValue == "ABF") { rptName = "BLPrintFwdABF.rdlc"; } else if (ddlLine.SelectedValue == "BLP") { rptName = "BLPrintFwdBLPL.rdlc"; } else { rptName = "BLPrintFwdSim.rdlc"; } rptViewer.Reset(); rptViewer.LocalReport.Dispose(); rptViewer.LocalReport.DataSources.Clear(); rptViewer.LocalReport.ReportPath = this.Server.MapPath(this.Request.ApplicationPath) + ConfigurationManager.AppSettings["ReportPath"].ToString() + "/" + rptName; rptViewer.LocalReport.DataSources.Add(new ReportDataSource("DSFWDBLPrinting", temp.Tables[0])); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsBLPrintingContainerTopFive", dtBLPrintingCons5)); rptViewer.LocalReport.DataSources.Add(new ReportDataSource("dsBLPrintingContainer", dtBLPrintingCons)); rptViewer.LocalReport.SetParameters(new ReportParameter("ImageShow", "false")); rptViewer.LocalReport.Refresh(); } }