Exemplo n.º 1
0
        private ReportParameter[] CreateReportParameters(KnittingJoParameters parameters)
        {
            List<ReportParameter> reportParameters = new List<ReportParameter>();
            PropertyInfo[] propertyInfos = parameters.GetType().GetProperties();
            foreach (PropertyInfo pInfo in propertyInfos)
            {
                ReportParameter parameter = new ReportParameter(pInfo.Name, (string)pInfo.GetValue(parameters));
                reportParameters.Add(parameter);
            }

            return reportParameters.ToArray();
        }
Exemplo n.º 2
0
        public KnittingJoParameters GetReportParameters()
        {
            KnittingJoParameters parameters = new KnittingJoParameters();

            parameters.JoOrderNo = JO.JoNoWrapper;
            parameters.QualitySpecification = JO.QualitySpecifications;
            parameters.JoDate = JO.JoDate.ToString("dd/MM/yyyy");
            parameters.QuoteDate = JO.QuoteDate.ToString("dd/MM/yyyy");
            parameters.QuoteNumber = JO.QuoteNo;
            parameters.SupplierInformation = Constants.GetSupplierInformation(JO.Company);
            parameters.TermsAndConditions = JO.TermsAndConditions;

            return parameters;
        }
Exemplo n.º 3
0
 public void SetParameters(KnittingJoParameters parameters)
 {
     this.reportViewer1.LocalReport.SetParameters(CreateReportParameters(parameters));
 }
Exemplo n.º 4
0
 public KnittingJoGenerator(KnittingJO jo, KnittingJoParameters parameters)
 {
     knittingJoContol = new Reports.KnittingJoControl();
     JO = jo;
     Parameters = parameters;
 }