Exemplo n.º 1
0
        /// <summary>
        /// RDLs to PDF.
        /// </summary>
        private void RdlToPdf()
        {
            string[,] param =
            {
                { "FromTxNumber", this.cboFrom.Text.Trim()                                        },
                { "ToTxNumber",   this.cboTo.Text.Trim()                                          },
                { "FromDate",     this.dtpDateFrom.Value.ToString(DateTimeHelper.GetDateFormat()) },
                { "ToDate",       this.dtpDateTo.Value.ToString(DateTimeHelper.GetDateFormat())   },
                { "PrintedOn",    DateTime.Now.ToString(DateTimeHelper.GetDateTimeFormat())       },
                { "STKCODE",      SystemInfoHelper.Settings.GetSystemLabelByKey("STKCODE")        },
                { "Appendix1",    SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX1")      },
                { "Appendix2",    SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX2")      },
                { "Appendix3",    SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX3")      },
                { "Company",      SystemInfoHelper.Settings.GetSystemLabelByKey("Company")        }, ////test
                { "DateFormat",   DateTimeHelper.GetDateFormat()                                  }
            };

            RT2020.Controls.Reporting.RdlExport rdlExport = new RT2020.Controls.Reporting.RdlExport();

            rdlExport.Datasource           = this.BindData();
            rdlExport.ReportName           = "RT2020.Purchasing.Reports.Receiving.Reports.WorksheetReceivingRdl.rdlc";
            rdlExport.ReportDatasourceName = "RT2020_Controls_Reporting_DataSource_vwRptPurchaseOrderReceive";
            rdlExport.Parameters           = param;

            rdlExport.ToPdf();
        }
Exemplo n.º 2
0
        /// <summary>
        /// RDLs to PDF.
        /// </summary>
        private void RdlToPdf()
        {
            string[,] param =
            {
                { "Appendix1",   SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX1") },
                { "Appendix2",   SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX2") },
                { "Appendix3",   SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX3") },
                { "PrintedOn",   DateTime.Now.ToString(DateTimeHelper.GetDateTimeFormat())  },
                { "STKCODE",     SystemInfoHelper.Settings.GetSystemLabelByKey("STKCODE")   },
                { "CompanyName", SystemInfoHelper.Settings.GetSystemLabelByKey("Company")   },   ////test data
                { "DateFormat",  DateTimeHelper.GetDateFormat()                             }
            };

            RT2020.Controls.Reporting.RdlExport rdlExport = new RT2020.Controls.Reporting.RdlExport();

            rdlExport.Datasource = this.BindData();

            if (rdoActive.Checked)
            {
                rdlExport.ReportName = "RT2020.Purchasing.Reports.OfficialDocument.Reports.OfficialPurchaseOrderActiveMatrixRdl.rdlc";
            }
            else
            {
                rdlExport.ReportName = "RT2020.Purchasing.Reports.OfficialDocument.Reports.OfficialPurchaseOrderBatchMatrixRdl.rdlc";
            }

            rdlExport.ReportDatasourceName = "RT2020_Controls_Reporting_DataSource_vwRptPurchaseOrderDocument";
            rdlExport.Parameters           = param;

            rdlExport.ToPdf();
        }
Exemplo n.º 3
0
        /// <summary>
        /// RDLs to Supplier PDF.
        /// </summary>
        private void RdlToSuppPdf()
        {
            string[,] param =
            {
                { "FromSupplier", this.cboSuppFrom.Text.Trim()                                        },
                { "ToSupplier",   this.cboSuppTo.Text.Trim()                                          },
                { "FromDate",     this.dtpSuppDateFrom.Value.ToString(DateTimeHelper.GetDateFormat()) },
                { "ToDate",       this.dtpSuppDateTo.Value.ToString(DateTimeHelper.GetDateFormat())   },
                { "PrintedOn",    DateTime.Now.ToString(DateTimeHelper.GetDateTimeFormat())           },
                { "STKCODE",      SystemInfoHelper.Settings.GetSystemLabelByKey("STKCODE")            },
                { "Appendix1",    SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX1")          },
                { "Appendix2",    SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX2")          },
                { "Appendix3",    SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX3")          },
                { "Company",      SystemInfoEx.CurrentInfo.Default.CompanyName                        },
                { "DateFormat",   DateTimeHelper.GetDateFormat()                                      }
            };

            RT2020.Controls.Reporting.RdlExport rdlExport = new RT2020.Controls.Reporting.RdlExport();

            rdlExport.Datasource           = this.BindDataSupp();
            rdlExport.ReportName           = "RT2020.Purchasing.Reports.PurchaseOrder.Reports.WorksheetSuppStatusRdl.rdlc";
            rdlExport.ReportDatasourceName = "RT2020_Controls_Reporting_DataSource_vwRptPurchaseOrder";
            rdlExport.Parameters           = param;

            rdlExport.ToPdf();
        }
Exemplo n.º 4
0
        /// <summary>
        /// RDLs to PDF.
        /// </summary>
        private void RdlToPdf()
        {
            string[,] param =
            {
                { "FromCode",  this.cboFrom.Text.Trim()                                  },
                { "ToCode",    this.cboTo.Text.Trim()                                    },
                { "PrintedOn", DateTime.Now.ToString(DateTimeHelper.GetDateTimeFormat()) },
                { "Company",   SystemInfoHelper.Settings.GetSystemLabelByKey("Company")  } ////test data
            };

            RT2020.Controls.Reporting.RdlExport rdlExport = new RT2020.Controls.Reporting.RdlExport();

            rdlExport.Datasource           = this.BindData();
            rdlExport.ReportName           = "RT2020.Purchasing.Reports.Others.Reports.PORemarkRdl.rdlc";
            rdlExport.ReportDatasourceName = "RT2020_Controls_Reporting_DataSource_Remarks";
            rdlExport.Parameters           = param;

            rdlExport.ToPdf();
        }
Exemplo n.º 5
0
        /// <summary>
        /// RDLs to PDF.
        /// </summary>
        private void RdlToPdf()
        {
            string[,] param =
            {
                { "PrintedOn",  DateTime.Now.ToString(DateTimeHelper.GetDateTimeFormat())  },
                { "STKCODE",    SystemInfoHelper.Settings.GetSystemLabelByKey("STKCODE")   },
                { "Appendix1",  SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX1") },
                { "Appendix2",  SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX2") },
                { "Appendix3",  SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX3") },
                { "Company",    SystemInfoHelper.Settings.GetSystemLabelByKey("Company")   }, ////test
                { "DateFormat", DateTimeHelper.GetDateFormat()                             }
            };

            RT2020.Controls.Reporting.RdlExport rdlExport = new RT2020.Controls.Reporting.RdlExport();

            rdlExport.Datasource           = this.BindData();
            rdlExport.ReportName           = "RT2020.Purchasing.Reports.ReceivingSchedule.Reports.WorksheetPOQtyReceivingHistoryRdl.rdlc";
            rdlExport.ReportDatasourceName = "RT2020_Controls_Reporting_DataSource_vwRptPurchaseOrderReceive";
            rdlExport.Parameters           = param;

            rdlExport.ToPdf();
        }
Exemplo n.º 6
0
        /// <summary>
        /// RDLs to PDF.
        /// </summary>
        private void RdlToPdf()
        {
            string[,] param =
            {
                { "PrintedOn",  DateTime.Now.ToString(DateTimeHelper.GetDateTimeFormat())  },
                { "Appendix1",  SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX1") },
                { "Appendix2",  SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX2") },
                { "Appendix3",  SystemInfoHelper.Settings.GetSystemLabelByKey("APPENDIX3") },
                { "Company",    SystemInfoHelper.Settings.GetSystemLabelByKey("Company")   }, ////test
                { "DateFormat", DateTimeHelper.GetDateFormat()                             },
                { "STKCODE",    SystemInfoHelper.Settings.GetSystemLabelByKey("STKCODE")   }
            };

            RT2020.Controls.Reporting.RdlExport rdlExport = new RT2020.Controls.Reporting.RdlExport();

            rdlExport.Datasource = this.BindData();

            if (cboSortedBy.SelectedIndex == 0)
            {
                // SortedBy = Stock Code
                if (cboType.SelectedIndex == 0)
                {
                    ////Type = Active
                    if (chkPrintPhoto.Checked && chkHideAPPENDIX3.Checked)
                    {
                        ////Print out Item Photo AND Hide APPENDIX2
                        rdlExport.ReportName = "RT2020.Purchasing.Reports.OfficialDocument.Reports.OfficialPurchaseOrderActivePhotoMatrixByStockCodeRdl.rdlc";
                    }
                    else if (chkPrintPhoto.Checked && !chkHideAPPENDIX3.Checked)
                    {
                        ////Print out Item Photo
                    }
                    else if (!chkPrintPhoto.Checked && chkHideAPPENDIX3.Checked)
                    {
                        ////Hide APPENDIX2
                        rdlExport.ReportName = "RT2020.Purchasing.Reports.OfficialDocument.Reports.OfficialPurchaseOrderActiveMatrixByStockCodeRdl.rdlc";
                    }
                    else
                    {
                    }
                }
                else
                {
                    ////Type = Batch
                    if (chkPrintPhoto.Checked && chkHideAPPENDIX3.Checked)
                    {
                        ////Print out Item Photo AND Hide APPENDIX2
                        rdlExport.ReportName = "RT2020.Purchasing.Reports.OfficialDocument.Reports.OfficialPurchaseOrderBatchPhotoMatrixByStockCodeRdl.rdlc";
                    }
                    else if (chkPrintPhoto.Checked && !chkHideAPPENDIX3.Checked)
                    {
                        ////Print out Item Photo
                    }
                    else if (!chkPrintPhoto.Checked && chkHideAPPENDIX3.Checked)
                    {
                        ////Hide APPENDIX2
                        rdlExport.ReportName = "RT2020.Purchasing.Reports.OfficialDocument.Reports.OfficialPurchaseOrderBatchMatrixByStockCodeRdl.rdlc";
                    }
                    else
                    {
                    }
                }
            }
            else
            {
                // SortedBy = Supplier Number
                if (cboType.SelectedIndex == 0)
                {
                    ////Type = Active
                    if (chkPrintPhoto.Checked && chkHideAPPENDIX3.Checked)
                    {
                        ////Print out Item Photo AND Hide APPENDIX2
                    }
                    else if (chkPrintPhoto.Checked && !chkHideAPPENDIX3.Checked)
                    {
                        ////Print out Item Photo
                    }
                    else if (!chkPrintPhoto.Checked && chkHideAPPENDIX3.Checked)
                    {
                        ////Hide APPENDIX2
                    }
                    else
                    {
                    }
                }
                else
                {
                    ////Type = Batch
                    if (chkPrintPhoto.Checked && chkHideAPPENDIX3.Checked)
                    {
                        ////Print out Item Photo AND Hide APPENDIX2
                    }
                    else if (chkPrintPhoto.Checked && !chkHideAPPENDIX3.Checked)
                    {
                        ////Print out Item Photo
                    }
                    else if (!chkPrintPhoto.Checked && chkHideAPPENDIX3.Checked)
                    {
                        ////Hide APPENDIX2
                    }
                    else
                    {
                    }
                }
            }

            rdlExport.ReportDatasourceName = "RT2020_Controls_Reporting_DataSource_vwRptPurchaseOrderDocument";
            rdlExport.Parameters           = param;

            rdlExport.ToPdf();
        }