public static void Build() { ReportBuilder rptbuild = new ReportBuilder(); ReportType vReport = rptbuild.Report; BodyType vBody = vReport.Body; double x = 0, y = 0, wd = 0, ht = 0; vReport.Width.Value = RPT_WIDTH; vBody.Height.Value = RPT_HEIGHT; DataSetType dataSet = rptbuild.Report.DataSets[0]; ReportUtil.AddFields(dataSet.Fields, new string[] { POUTWARD.COPIES , POUTWARD.COMPANY_NAME , POUTWARD.ADDRESS1 , POUTWARD.ADDRESS2 , POUTWARD.COMPANY_GSTTIN , POUTWARD.OUTWARD_ID , POUTWARD.OUTWARD_NO , POUTWARD.OUTWARD_DATE , POUTWARD.PARTY_NAME , POUTWARD.STREET1 , POUTWARD.STREET2 , POUTWARD.CITY , POUTWARD.STATE , POUTWARD.COUNTRY , POUTWARD.PINCODE , POUTWARD.GSTIN , POUTWARD.TOTAL_QTY , POUTWARD.TOTAL_BUNDLE , POUTWARD.DELIVREDTHROUGH }); x = 0; y = 0; wd = RPT_WIDTH; ht = RPT_HEIGHT; ListType Reportlist = ReportUtil.AddList("Reportlist", vBody.ReportItems, x, y, wd, ht); Reportlist.Grouping = new GroupingType("group_" + POUTWARD.OUTWARD_ID + ""); Reportlist.Grouping.GroupExpressions.Add("=Fields!" + POUTWARD.OUTWARD_ID + ".Value"); Reportlist.Grouping.GroupExpressions.Add("=Fields!" + POUTWARD.COPIES + ".Value"); Reportlist.Grouping.PageBreakAtEnd = true; x = 0; y = 0; wd = RPT_WIDTH; ht = RPT_HEIGHT; RectangleType rectWarper = ReportUtil.AddRectangle("rectWarper", Reportlist.ReportItems, x, y, wd, ht); rectWarper.Style.BorderStyle.Default = BorderStyleEnum.None; BuildDetail(rectWarper); //ReportUtil.AttachRulers(Reportlist.ReportItems, RPT_WIDTH, RPT_HEIGHT); rptbuild.SaveAs(PRINT_FOLDER + @"\P_Outward.rdlc"); }
private static void BuildDetail(BodyType rectWarper) { double x = 0, y = 0, wd = 0, ht = 0; string sufx = ""; /*Now unused. Used before in A4 (i.e 2xA5) print*/ // x = 0; y = 0; wd = 7.65; ht = 0.1; RectangleType subrect = ReportUtil.AddRectangle("manirect" + sufx, rectWarper.ReportItems, x, y, wd, ht); subrect.Style.BorderStyle.Default = BorderStyleEnum.None; //subrect.Style.BackgroundColor.Color = Color.Red; // #region [HEADING AREA] // x = 0; y = 0; wd = subrect.Width.Value; ht = 0.3; RectangleType heading = ReportUtil.AddRectangle("heading" + sufx, subrect.ReportItems, x, y, wd, ht); heading.Style.BorderStyle.Default = BorderStyleEnum.Outset; //heading.Style.BackgroundColor.Color = Color.Orange; x = 6.8; y = 0; wd = 0.03; ht = 0.3; RectangleType heading_line = ReportUtil.AddRectangle("heading_line" + sufx, subrect.ReportItems, x, y, wd, ht); heading_line.Style.BorderStyle.Default = BorderStyleEnum.None; heading_line.Style.BorderStyle.Left = BorderStyleEnum.Outset; //heading_line.Style.BackgroundColor.Color = Color.Orange; // #endregion [HEADING AREA] // #region [Lines AREA] // x = 0; y = 0; wd = 0.23; ht = 4.8; RectangleType slno = ReportUtil.AddRectangle("slno" + sufx, subrect.ReportItems, x, y, wd, ht); slno.Style.BorderStyle.Default = BorderStyleEnum.Outset; //slno.Style.BackgroundColor.Color = Color.MistyRose; // x = x + slno.Width.Value; y = 0; wd = 2.12; ht = ht + 0; RectangleType particulars = ReportUtil.AddRectangle("particulars" + sufx, subrect.ReportItems, x, y, wd, ht); particulars.Style.BorderStyle.Default = BorderStyleEnum.Outset; //particulars.Style.BackgroundColor.Color = Color.FloralWhite; // x = x + particulars.Width.Value; y = 0; wd = 0.7; ht = ht + 0; RectangleType hsn_code = ReportUtil.AddRectangle("hsn_code" + sufx, subrect.ReportItems, x, y, wd, ht); hsn_code.Style.BorderStyle.Default = BorderStyleEnum.Outset; // hsn_code.Style.BackgroundColor.Color = Color.Chocolate; // x = x + hsn_code.Width.Value; y = 0; wd = 0.4; ht = ht + 0; RectangleType qtys = ReportUtil.AddRectangle("qtys" + sufx, subrect.ReportItems, x, y, wd, ht); qtys.Style.BorderStyle.Default = BorderStyleEnum.Outset; //qtys.Style.BackgroundColor.Color = Color.SaddleBrown; x = x + qtys.Width.Value; y = 0; wd = 0.4; ht = ht + 0; RectangleType widths = ReportUtil.AddRectangle("widths" + sufx, subrect.ReportItems, x, y, wd, ht); widths.Style.BorderStyle.Default = BorderStyleEnum.Outset; //widths.Style.BackgroundColor.Color = Color.Aquamarine; x = x + widths.Width.Value; y = 0; wd = 0.4; ht = ht + 0; RectangleType heights = ReportUtil.AddRectangle("heights" + sufx, subrect.ReportItems, x, y, wd, ht); heights.Style.BorderStyle.Default = BorderStyleEnum.Outset; //heights.Style.BackgroundColor.Color = Color.Aquamarine; x = x + heights.Width.Value; y = 0; wd = 0.5; ht = ht + 0; RectangleType areasq = ReportUtil.AddRectangle("areasq" + sufx, subrect.ReportItems, x, y, wd, ht); areasq.Style.BorderStyle.Default = BorderStyleEnum.Outset; //areasq.Style.BackgroundColor.Color = Color.Aquamarine; x = x + areasq.Width.Value; y = 0; wd = 0.5; ht = ht + 0; RectangleType price = ReportUtil.AddRectangle("price" + sufx, subrect.ReportItems, x, y, wd, ht); price.Style.BorderStyle.Default = BorderStyleEnum.Outset; //price.Style.BackgroundColor.Color = Color.Aquamarine; // x = x + price.Width.Value; y = 0; wd = 0.7; ht = ht + 0; RectangleType taxableamt = ReportUtil.AddRectangle("taxableamt" + sufx, subrect.ReportItems, x, y, wd, ht); taxableamt.Style.BorderStyle.Default = BorderStyleEnum.Outset; //amount.Style.BackgroundColor.Color = Color.Green; // x = x + taxableamt.Width.Value; y = 0.3; wd = 0.2; ht = ht - 0.3; RectangleType sgst_per = ReportUtil.AddRectangle("sgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); sgst_per.Style.BorderStyle.Default = BorderStyleEnum.Outset; //sgst_per.Style.BackgroundColor.Color = Color.Firebrick; x = x + sgst_per.Width.Value; y = 0.3; wd = 0.65; ht = ht + 0; RectangleType sgst_amt = ReportUtil.AddRectangle("sgst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); sgst_amt.Style.BorderStyle.Default = BorderStyleEnum.Outset; //sgst_amt.Style.BackgroundColor.Color = Color.DodgerBlue; x = x + sgst_amt.Width.Value; y = 0.3; wd = 0.2; ht = ht + 0; RectangleType cgst_per = ReportUtil.AddRectangle("cgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); cgst_per.Style.BorderStyle.Default = BorderStyleEnum.Outset; //cgst_per.Style.BackgroundColor.Color = Color.DarkGoldenrod; x = x + cgst_per.Width.Value; y = 0.3; wd = 0.65; ht = ht + 0; RectangleType cgst_amt = ReportUtil.AddRectangle("cgst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); cgst_amt.Style.BorderStyle.Default = BorderStyleEnum.Outset; // cgst_amt.Style.BackgroundColor.Color = Color.Yellow; #endregion [Lines AREA] // #region [Header ] /// x = slno.Left.Value + 0.01; y = 0.09; wd = slno.Width.Value - 0.03; ht = 0.16; TextboxType lbl_slno = ReportUtil.AddTextbox("lbl_slno" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_slno.Value = "S.No"; lbl_slno.Style.Font("Calibri", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_slno.Style.TextAlign = TextAlignRptEnum.Center; //lbl_slno.Style.BackgroundColor.Color = Color.Salmon; /// x = particulars.Left.Value + 0.11; y = y + 0; wd = particulars.Width.Value - 0.13; ht = 0.16; TextboxType lbl_particulars = ReportUtil.AddTextbox("lbl_particulars" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_particulars.Value = "Description"; lbl_particulars.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_particulars.Style.TextAlign = TextAlignRptEnum.Center; //lbl_particulars.Style.BackgroundColor.Color = Color.SteelBlue; x = hsn_code.Left.Value + 0.12; y = y + 0; wd = hsn_code.Width.Value - 0.08; ht = 0.16; TextboxType lbl_hsn = ReportUtil.AddTextbox("lbl_hsn" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_hsn.Value = "HSN Code"; lbl_hsn.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_hsn.Style.TextAlign = TextAlignRptEnum.Left; //lbl_hsn_code.Style.BackgroundColor.Color = Color.Blue; x = qtys.Left.Value + 0.01; y = 0.09; wd = qtys.Width.Value - 0.03; ht = 0.16; TextboxType lbl_qty = ReportUtil.AddTextbox("lbl_qty" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_qty.Value = "QTY"; lbl_qty.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_qty.Style.TextAlign = TextAlignRptEnum.Center; //lbl_qty.Style.BackgroundColor.Color = Color.DimGray; /// x = widths.Left.Value + 0.01; y = y + 0; wd = widths.Width.Value - 0.03; ht = 0.16; TextboxType lbl_widths = ReportUtil.AddTextbox("lbl_widths" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_widths.Value = "Width"; lbl_widths.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_widths.Style.TextAlign = TextAlignRptEnum.Center; //lbl_widths.Style.BackgroundColor.Color = Color.SeaGreen; x = heights.Left.Value + 0.01; y = y + 0; wd = heights.Width.Value - 0.03; ht = 0.16; TextboxType lbl_heights = ReportUtil.AddTextbox("lbl_heights" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_heights.Value = "Height"; lbl_heights.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_heights.Style.TextAlign = TextAlignRptEnum.Center; // lbl_heights.Style.BackgroundColor.Color = Color.Bisque; x = areasq.Left.Value + 0.01; y = y + 0; wd = areasq.Width.Value - 0.03; ht = 0.16; TextboxType lbl_areasq = ReportUtil.AddTextbox("lbl_areasq" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_areasq.Value = "Area sq"; lbl_areasq.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_areasq.Style.TextAlign = TextAlignRptEnum.Center; //lbl_areasq.Style.BackgroundColor.Color = Color.Bisque; x = price.Left.Value + 0.01; y = y + 0; wd = price.Width.Value - 0.03; ht = 0.16; TextboxType lbl_price = ReportUtil.AddTextbox("lbl_price" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_price.Value = "Price"; lbl_price.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_price.Style.TextAlign = TextAlignRptEnum.Center; //lbl_price.Style.BackgroundColor.Color = Color.Coral; /// x = taxableamt.Left.Value + 0.01; y = 0.03; wd = taxableamt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_taxableamt = ReportUtil.AddTextbox("lbl_taxableamt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_taxableamt.Value = "Taxable"; lbl_taxableamt.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_taxableamt.Style.TextAlign = TextAlignRptEnum.Center; //lbl_taxableamt.Style.BackgroundColor.Color = Color.Wheat; x = taxableamt.Left.Value + 0.01; y = y + 0.12; wd = taxableamt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_taxableamount = ReportUtil.AddTextbox("lbl_taxableamount" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_taxableamount.Value = "Amt"; lbl_taxableamount.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_taxableamount.Style.TextAlign = TextAlignRptEnum.Center; //lbl_taxableamt.Style.BackgroundColor.Color = Color.Wheat; x = sgst_per.Left.Value + 0.01; y = 0.02; wd = sgst_per.Width.Value + sgst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sgst = ReportUtil.AddTextbox("lbl_sgst" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sgst.Value = " SGST"; lbl_sgst.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sgst.Style.TextAlign = TextAlignRptEnum.Center; // lbl_sgst.Style.BackgroundColor.Color = Color.Violet; x = sgst_per.Left.Value + 0.03; y = y + 0.1; wd = sgst_per.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sgst_per = ReportUtil.AddTextbox("lbl_sgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sgst_per.Value = " %"; lbl_sgst_per.Style.Font("Calibri", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sgst_per.Style.TextAlign = TextAlignRptEnum.Left; //lbl_sgst_per.Style.BackgroundColor.Color = Color.Aquamarine; x = sgst_amt.Left.Value + 0.01; y = y + 0.03; wd = sgst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sgst_amt = ReportUtil.AddTextbox("lbl_sgst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sgst_amt.Value = " Amt"; lbl_sgst_amt.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sgst_amt.Style.TextAlign = TextAlignRptEnum.Left; //lbl_sgst_amt.Style.BackgroundColor.Color = Color.DimGray; x = cgst_per.Left.Value + 0.01; y = 0.02; wd = cgst_per.Width.Value + cgst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_cgst = ReportUtil.AddTextbox("lbl_cgst" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_cgst.Value = " CGST"; lbl_cgst.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_cgst.Style.TextAlign = TextAlignRptEnum.Center; //lbl_cgst.Style.BackgroundColor.Color = Color.Cyan; x = cgst_per.Left.Value + 0.03; y = y + 0.1; wd = cgst_per.Width.Value - 0.03; ht = 0.16; TextboxType lbl_cgst_per = ReportUtil.AddTextbox("lbl_cgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_cgst_per.Value = " %"; lbl_cgst_per.Style.Font("Calibri", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_cgst_per.Style.TextAlign = TextAlignRptEnum.Left; //lbl_cgst_per.Style.BackgroundColor.Color = Color.Goldenrod; x = cgst_amt.Left.Value + 0.02; y = y + 0.03; wd = cgst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_cgst_amt = ReportUtil.AddTextbox("lbl_cgst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_cgst_amt.Value = " Amt"; lbl_cgst_amt.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_cgst_amt.Style.TextAlign = TextAlignRptEnum.Left; //lbl_cgst_amt.Style.BackgroundColor.Color = Color.Khaki; #endregion [Header] // #region [ Detail-Line ] // x = 0; y = 0.4; wd = subrect.Width.Value; ht = 0.03; ListType listDetlLine = ReportUtil.AddList("listDetlLine" + sufx, subrect.ReportItems, x, y, wd, ht); listDetlLine.DataSetName = "MyDataSource_Items"; listDetlLine.Grouping = new GroupingType("group_" + PQuotationitems.SL_NO + ""); listDetlLine.Grouping.GroupExpressions.Add("=Fields!" + PQuotationitems.SL_NO + ".Value"); //listDetlLine.Style.BackgroundColor.Color = Color.Red; // x = 0; y = 0; wd = 0.55; ht = 0.25; RectangleType listdetails_rect = ReportUtil.AddRectangle("listdetails_rect" + sufx, listDetlLine.ReportItems, x, y, wd, ht); listdetails_rect.Style.BorderStyle.Default = BorderStyleEnum.None; //listdetails_rect.Style.BackgroundColor.Color = Color.Azure; // x = slno.Left.Value + 0.01; y = 0; wd = slno.Width.Value - 0.03; ht = ht + 0; TextboxType txt_slno = ReportUtil.AddTextbox("txt_slno" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_slno.Value = "=Fields!" + PQuotationitems.SL_NO + ".Value"; txt_slno.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); txt_slno.Style.TextAlign = TextAlignRptEnum.Center; x = particulars.Left.Value + 0.05; y = 0; wd = particulars.Width.Value - 0.05; ht = ht + 0; TextboxType txt_product_name = ReportUtil.AddTextbox("txt_product_name" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_product_name.Value = "=Fields!" + PQuotationitems.PRODUCT_ID + ".Value"; txt_product_name.Style.TextAlign = TextAlignRptEnum.Left; txt_product_name.CanGrow = true; txt_product_name.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); x = hsn_code.Left.Value + 0.01; y = 0; wd = hsn_code.Width.Value - 0.02; ht = ht + 0; TextboxType txt_hsn_code = ReportUtil.AddTextbox("txt_hsn_code" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_hsn_code.Value = "=Fields!" + PQuotationitems.HSN_CODE_ID + ".Value"; txt_hsn_code.Style.TextAlign = TextAlignRptEnum.Center; txt_hsn_code.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_hsn_code.Style.BackgroundColor.Color = Color.Red; x = qtys.Left.Value + 0.02; y = 0; wd = qtys.Width.Value - 0.05; ht = ht + 0; TextboxType txt_qty = ReportUtil.AddTextbox("txt_qty" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_qty.Value = "=Fields!" + PQuotationitems.QTY + ".Value"; txt_qty.Style.TextAlign = TextAlignRptEnum.Center; txt_qty.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_qty.Style.BackgroundColor.Color = Color.Red; x = widths.Left.Value + 0.01; y = 0; wd = widths.Width.Value - 0.03; ht = ht + 0; TextboxType txt_widths = ReportUtil.AddTextbox("txt_widths" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_widths.Value = "=Fields!" + PQuotationitems.WIDTHS + ".Value"; txt_widths.Style.TextAlign = TextAlignRptEnum.Center; txt_widths.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); // x = heights.Left.Value + 0.01; y = 0; wd = heights.Width.Value - 0.03; ht = ht + 0; TextboxType txt_heights = ReportUtil.AddTextbox("txt_heights" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_heights.Value = "=Fields!" + PQuotationitems.HEIGTHS + ".Value"; txt_heights.Style.TextAlign = TextAlignRptEnum.Center; txt_heights.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_heights.Style.BackgroundColor.Color = Color.Red; x = areasq.Left.Value + 0.01; y = 0; wd = areasq.Width.Value - 0.03; ht = ht + 0; TextboxType txt_areasq = ReportUtil.AddTextbox("txt_areasq" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_areasq.Value = "=Fields!" + PQuotationitems.AREASQ + ".Value"; txt_areasq.Style.TextAlign = TextAlignRptEnum.Center; txt_areasq.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_areasq.Style.BackgroundColor.Color = Color.Red; x = price.Left.Value + 0.02; y = 0; wd = price.Width.Value - 0.05; ht = ht + 0; TextboxType txt_price = ReportUtil.AddTextbox("txt_price" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_price.Value = "=Fields!" + PQuotationitems.PRICE + ".Value"; txt_price.Style.TextAlign = TextAlignRptEnum.Right; txt_price.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_price.Style.BackgroundColor.Color = Color.Red; x = taxableamt.Left.Value + 0.01; y = 0; wd = taxableamt.Width.Value - 0.04; ht = ht + 0; TextboxType txt_taxable = ReportUtil.AddTextbox("txt_taxable" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_taxable.Value = "=Fields!" + PQuotationitems.TAXABLEVALUE + ".Value"; txt_taxable.Style.TextAlign = TextAlignRptEnum.Right; txt_taxable.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_taxable.Style.BackgroundColor.Color = Color.Red; x = sgst_per.Left.Value + 0.01; y = 0; wd = sgst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_sgst_per = ReportUtil.AddTextbox("txt_sgst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sgst_per.Value = "=Fields!" + PQuotationitems.SGST_PERCENT + ".Value"; txt_sgst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_sgst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_sgst_per.Style.BackgroundColor.Color = Color.Red; x = sgst_amt.Left.Value; y = 0; wd = sgst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_sgst_amt = ReportUtil.AddTextbox("txt_sgst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sgst_amt.Value = "=Fields!" + PQuotationitems.SGST_AMOUNT + ".Value"; txt_sgst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_sgst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_sgst_amt.Style.BackgroundColor.Color = Color.Red; x = cgst_per.Left.Value + 0.01; y = 0; wd = cgst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_cgst_per = ReportUtil.AddTextbox("txt_cgst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_cgst_per.Value = "=Fields!" + PQuotationitems.CGST_PERCENT + ".Value"; txt_cgst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_cgst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_cgst_per.Style.BackgroundColor.Color = Color.Red; x = cgst_amt.Left.Value; y = 0; wd = cgst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_cgst_amt = ReportUtil.AddTextbox("txt_cgst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_cgst_amt.Value = "=Fields!" + PQuotationitems.CGST_AMOUNT + ".Value"; txt_cgst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_cgst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_cgst_amt.Style.BackgroundColor.Color = Color.ForestGreen; #endregion [Detail-Line] // } // fn build details
public static void Build() { ReportBuilder rptbuild = new ReportBuilder(); ReportType vReport = rptbuild.Report; BodyType vBody = vReport.Body; double x = 0, y = 0, wd = 0, ht = 0; vReport.Width.Value = RPT_WIDTH; vBody.Height.Value = RPT_HEIGHT; DataSetType dataSet = rptbuild.Report.DataSets[0]; ReportUtil.AddFields(dataSet.Fields, new string[] { PQuotation.COPIES , PQuotation.SALESTYPE , PQuotation.COMPANY_NAME , PQuotation.ADDRESS1 , PQuotation.ADDRESS2 , PQuotation.COMPANY_TIN , PQuotation.QUOTATION_ID , PQuotation.QUOTATION_NO , PQuotation.QUOTATION_DATE , PQuotation.TRANSPORT , PQuotation.DELIVERYTO , PQuotation.BUNDEL , PQuotation.PARTY_NAME , PQuotation.STREET1 , PQuotation.STREET2 , PQuotation.CITY , PQuotation.STATE , PQuotation.COUNTRY , PQuotation.PINCODE , PQuotation.GSTIN , PQuotation.TOTAL_QTY , PQuotation.TAXABLE_VALUE , PQuotation.TOTAL_SUB , PQuotation.LEDGER , PQuotation.ADDITIONAL , PQuotation.OUTSTANDING , PQuotation.GSTTOTAL , PQuotation.GRANDTOTAL , PQuotation.AMOUNT_IN_WORDS , PQuotation.NOTES , PQuotation.ENTRY_BY }); x = 0; y = 0; wd = RPT_WIDTH; ht = RPT_HEIGHT; ListType Reportlist = ReportUtil.AddList("Reportlist", vBody.ReportItems, x, y, wd, ht); Reportlist.Grouping = new GroupingType("group_" + PQuotation.QUOTATION_ID + ""); Reportlist.Grouping.GroupExpressions.Add("=Fields!" + PQuotation.QUOTATION_ID + ".Value"); Reportlist.Grouping.GroupExpressions.Add("=Fields!" + PQuotation.COPIES + ".Value"); Reportlist.Grouping.PageBreakAtEnd = true; x = 0; y = 0; wd = RPT_WIDTH; ht = RPT_HEIGHT; RectangleType rectWarper = ReportUtil.AddRectangle("rectWarper", Reportlist.ReportItems, x, y, wd, ht); rectWarper.Style.BorderStyle.Default = BorderStyleEnum.None; BuildDetail(rectWarper); //ReportUtil.AttachRulers(Reportlist.ReportItems, RPT_WIDTH, RPT_HEIGHT); rptbuild.SaveAs(PRINT_FOLDER + @"\P_Quotation.rdlc"); }
public static void build() { ReportBuilder rptbuild = new ReportBuilder(); ReportType vReport = rptbuild.Report; BodyType vBody = vReport.Body; double x = 0, y = 0, wd = 0, ht = 0; vReport.Width.Value = RPT_WIDTH; vBody.Height.Value = RPT_HEIGHT; DataSetType dataSet = rptbuild.Report.DataSets[0]; ReportUtil.AddFields(dataSet.Fields, new string[] { PInvoice.COPIES , PInvoice.COMPANY_NAME , PInvoice.ADDRESS1 , PInvoice.ADDRESS2 , PInvoice.COMPANY_TIN , PInvoice.COMPANY_GST , PInvoice.SALES_TYPE , PInvoice.INVOICE_ID , PInvoice.INVOICE_NO , PInvoice.INVOICE_DATE , PInvoice.TRANSPORT , PInvoice.VEHICLE_NO , PInvoice.PLACE , PInvoice.PARTY_NAME , PInvoice.STREET1 , PInvoice.STREET2 , PInvoice.CITY , PInvoice.STATE , PInvoice.COUNTRY , PInvoice.PINCODE , PInvoice.GSTIN , PInvoice.SHIPPING_NAME , PInvoice.SHIPPING_STREET1 , PInvoice.SHIPPING_STREET2 , PInvoice.SHIPPING_CITY , PInvoice.SHIPPING_STATE , PInvoice.SHIPPING_COUNTRY , PInvoice.SHIPPING_PINCODE , PInvoice.SHIPPING_GSTIN , PInvoice.TOTAL_QTY , PInvoice.TOTAL_AREASQ , PInvoice.TAXABLE_VALUE , PInvoice.LBL_SGST , PInvoice.TOTAL_SGST , PInvoice.LBL_CGST , PInvoice.TOTAL_CGST , PInvoice.TOTAL_SUB , PInvoice.LEDGER , PInvoice.ADDITIONAL , PInvoice.ROUNDS , PInvoice.GSTTOTAL , PInvoice.GRANDTOTAL , PInvoice.AMOUNT_IN_WORDS , PInvoice.NOTES , PInvoice.ENTRY_BY }); x = 0; y = 0; wd = RPT_WIDTH; ht = RPT_HEIGHT; ListType Reportlist = ReportUtil.AddList("Reportlist", vBody.ReportItems, x, y, wd, ht); Reportlist.Grouping = new GroupingType("group_" + PInvoice.INVOICE_ID + ""); Reportlist.Grouping.GroupExpressions.Add("=Fields!" + PInvoice.INVOICE_ID + ".Value"); Reportlist.Grouping.GroupExpressions.Add("=Fields!" + PInvoice.COPIES + ".Value"); Reportlist.Grouping.PageBreakAtEnd = true; EmbeddedImageType myEmbeddedImage1 = ReportUtil.EmbedImage("Image1", Global.GetAbsolutePath("PRINTS\\sms_logo.png"), vReport); ImageType myImage1 = ReportUtil.AddImage("Image1", myEmbeddedImage1, Reportlist.ReportItems, 0.5, 0.4, 1.25, 1); myImage1.Sizing = SizingEnum.FitProportional; //.AutoSize //.Fit //.Clip x = 0; y = 0; wd = RPT_WIDTH; ht = RPT_HEIGHT; RectangleType rectWarper = ReportUtil.AddRectangle("rectWarper", Reportlist.ReportItems, x, y, wd, ht); rectWarper.Style.BorderStyle.Default = BorderStyleEnum.None; BuildDetail(rectWarper); rptbuild.SaveAs(PRINT_FOLDER + @"\P_Invoice.rdlc"); }
public static void Build() { ReportBuilder rptbuild = new ReportBuilder(); ReportType vReport = rptbuild.Report; BodyType vBody = vReport.Body; double x = 0, y = 0, wd = 0, ht = 0; vReport.Width.Value = RPT_WIDTH; vBody.Height.Value = RPT_HEIGHT; DataSetType dataSet = rptbuild.Report.DataSets[0]; ReportUtil.AddFields(dataSet.Fields, new string[] { PPurchase.COPIES , PPurchase.SALESTYPE , PPurchase.COMPANY_NAME , PPurchase.ADDRESS1 , PPurchase.ADDRESS2 , PPurchase.COMPANY_TIN , PPurchase.PURCHASE_ID , PPurchase.PURCHASE_NO , PPurchase.PURCHASE_DATE , PPurchase.PARTY_NAME , PPurchase.STREET1 , PPurchase.STREET2 , PPurchase.CITY , PPurchase.STATE , PPurchase.COUNTRY , PPurchase.PINCODE , PPurchase.GSTIN , PPurchase.TOTAL_QTY , PPurchase.TAXABLE_VALUE , PPurchase.LBL_CGST , PPurchase.LBL_SGST , PPurchase.TOTAL_CGST , PPurchase.TOTAL_SGST , PPurchase.TOTAL_IGST , PPurchase.TOTAL_CESS , PPurchase.TOTAL_SUB , PPurchase.LEDGER , PPurchase.ADDITIONAL , PPurchase.ROUNDS , PPurchase.GSTTOTAL , PPurchase.GRANDTOTAL , PPurchase.AMOUNT_IN_WORDS , PPurchase.NOTES , PPurchase.ENTRY_BY }); x = 0; y = 0; wd = RPT_WIDTH; ht = RPT_HEIGHT; ListType Reportlist = ReportUtil.AddList("Reportlist", vBody.ReportItems, x, y, wd, ht); Reportlist.Grouping = new GroupingType("group_" + PPurchase.PURCHASE_ID + ""); Reportlist.Grouping.GroupExpressions.Add("=Fields!" + PPurchase.PURCHASE_ID + ".Value"); Reportlist.Grouping.GroupExpressions.Add("=Fields!" + PPurchase.COPIES + ".Value"); Reportlist.Grouping.PageBreakAtEnd = true; if (Customise.PrintPurchaseWithLogo == true) { EmbeddedImageType myEmbeddedImage1 = ReportUtil.EmbedImage("Image1", Global.GetAbsolutePath("PRINTS\\" + Customise.Logo + ""), vReport); ImageType myImage1 = ReportUtil.AddImage("Image1", myEmbeddedImage1, Reportlist.ReportItems, 1.2, 0.4, 0.8, 0.8); myImage1.Sizing = SizingEnum.FitProportional; //.AutoSize //.Fit //.Clip } x = 0; y = 0; wd = RPT_WIDTH; ht = RPT_HEIGHT; RectangleType rectWarper = ReportUtil.AddRectangle("rectWarper", Reportlist.ReportItems, x, y, wd, ht); rectWarper.Style.BorderStyle.Default = BorderStyleEnum.None; BuildDetail(rectWarper); //ReportUtil.AttachRulers(Reportlist.ReportItems, RPT_WIDTH, RPT_HEIGHT); rptbuild.SaveAs(PRINT_FOLDER + @"\P_Purchase.rdlc"); }
private static void BuildDetail(BodyType rectWarper) { double x = 0, y = 0, wd = 0, ht = 0; string sufx = ""; /*Now unused. Used before in A4 (i.e 2xA5) print*/ // x = 0; y = 0; wd = 7.65; ht = 0.1; RectangleType subrect = ReportUtil.AddRectangle("manirect" + sufx, rectWarper.ReportItems, x, y, wd, ht); subrect.Style.BorderStyle.Default = BorderStyleEnum.None; //subrect.Style.BackgroundColor.Color = Color.Red; // #region [HEADING AREA] // x = 0; y = 0; wd = subrect.Width.Value; ht = 0.3; RectangleType heading = ReportUtil.AddRectangle("heading" + sufx, subrect.ReportItems, x, y, wd, ht); heading.Style.BorderStyle.Default = BorderStyleEnum.Outset; //heading.Style.BackgroundColor.Color = Color.Orange; //x = 6.2; y = 0; wd = 0.03; ht = 0.3; //RectangleType heading_line = ReportUtil.AddRectangle("heading_line" + sufx, subrect.ReportItems, x, y, wd, ht); //heading_line.Style.BorderStyle.Default = BorderStyleEnum.None; //heading_line.Style.BorderStyle.Left = BorderStyleEnum.Outset; ////heading_line.Style.BackgroundColor.Color = Color.Orange; // #endregion [HEADING AREA] // #region [Lines AREA] // x = 0; y = 0; wd = 0.23; ht = Customised.SubReportHeight; RectangleType slno = ReportUtil.AddRectangle("slno" + sufx, subrect.ReportItems, x, y, wd, ht); slno.Style.BorderStyle.Default = BorderStyleEnum.Outset; //slno.Style.BackgroundColor.Color = Color.MistyRose; RectangleType po = new RectangleType(""); RectangleType dc = new RectangleType(""); RectangleType hsn_code = new RectangleType(""); RectangleType particulars = new RectangleType(""); RectangleType sizes = new RectangleType(""); RectangleType qtys = new RectangleType(""); RectangleType price = new RectangleType(""); RectangleType taxableamt = new RectangleType(""); RectangleType cgst_per = new RectangleType(""); RectangleType cgst_amt = new RectangleType(""); RectangleType sgst_per = new RectangleType(""); RectangleType sgst_amt = new RectangleType(""); RectangleType igst_per = new RectangleType(""); RectangleType igst_amt = new RectangleType(""); RectangleType sub_total = new RectangleType(""); if (Customised.WithPo == true) { x = slno.Width.Value; y = 0; wd = 0.45; ht = ht + 0; po = ReportUtil.AddRectangle("po" + sufx, subrect.ReportItems, x, y, wd, ht); po.Style.BorderStyle.Default = BorderStyleEnum.None; //po.Style.BackgroundColor.Color = Color.Green; x = x + po.Width.Value; y = 0; wd = 0.45; ht = ht + 0; dc = ReportUtil.AddRectangle("dc" + sufx, subrect.ReportItems, x, y, wd, ht); dc.Style.BorderStyle.Default = BorderStyleEnum.Outset; //dc.Style.BackgroundColor.Color = Color.Blue; x = x + dc.Width.Value; y = 0; wd = 0.5; ht = ht + 0; } else { x = x + slno.Width.Value; y = 0; wd = 0.5; ht = ht + 0; } hsn_code = ReportUtil.AddRectangle("hsn_code" + sufx, subrect.ReportItems, x, y, wd, ht); hsn_code.Style.BorderStyle.Default = BorderStyleEnum.Outset; // hsn_code.Style.BackgroundColor.Color = Color.Chocolate; if (Customised.WithSizes == true) { if (Customised.TaxType == Core.SGST) { x = x + hsn_code.Width.Value; y = 0; wd = 2.652; ht = ht + 0; } else if (Customised.TaxType == Core.IGST) { x = x + hsn_code.Width.Value; y = 0; wd = 3.17; ht = ht + 0; } } //else if (PrintConfig.With_sizes == false) //{ // if (PrintConfig.TaxType == Core.SGST) // { // x = x + hsn_code.Width.Value; y = 0; wd = 3; ht = ht + 0; // } // else if (PrintConfig.TaxType == Core.IGST) // { // x = x + hsn_code.Width.Value; y = 0; wd = 3.52; ht = ht + 0; // } //} if (Customised.WithPo == true) { if (Customised.TaxType == Core.SGST) { x = x + hsn_code.Width.Value; y = 0; wd = 2.1; ht = ht + 0; } else if (Customised.TaxType == Core.IGST) { x = x + hsn_code.Width.Value; y = 0; wd = 2.62; ht = ht + 0; } } particulars = ReportUtil.AddRectangle("particulars" + sufx, subrect.ReportItems, x, y, wd, ht); particulars.Style.BorderStyle.Default = BorderStyleEnum.Outset; //particulars.Style.BackgroundColor.Color = Color.FloralWhite; if (Customised.WithSizes == true) { x = x + particulars.Width.Value; y = 0; wd = 0.35; ht = ht + 0; sizes = ReportUtil.AddRectangle("sizes" + sufx, subrect.ReportItems, x, y, wd, ht); sizes.Style.BorderStyle.Default = BorderStyleEnum.Outset; //sizes.Style.BackgroundColor.Color = Color.SaddleBrown; x = x + sizes.Width.Value; y = 0; wd = 0.6; ht = ht + 0; } else { x = x + particulars.Width.Value; y = 0; wd = 0.6; ht = ht + 0; } qtys = ReportUtil.AddRectangle("qtys" + sufx, subrect.ReportItems, x, y, wd, ht); qtys.Style.BorderStyle.Default = BorderStyleEnum.Outset; //qtys.Style.BackgroundColor.Color = Color.SaddleBrown; x = x + qtys.Width.Value; y = 0; wd = 0.45; ht = ht + 0; price = ReportUtil.AddRectangle("price" + sufx, subrect.ReportItems, x, y, wd, ht); price.Style.BorderStyle.Default = BorderStyleEnum.Outset; //price.Style.BackgroundColor.Color = Color.Aquamarine; x = x + price.Width.Value; y = 0; wd = 0.65; ht = ht + 0; taxableamt = ReportUtil.AddRectangle("taxableamt" + sufx, subrect.ReportItems, x, y, wd, ht); taxableamt.Style.BorderStyle.Default = BorderStyleEnum.Outset; //amount.Style.BackgroundColor.Color = Color.Green; double cgstwidth = 0; if (Customised.TaxType == Core.SGST) { x = x + taxableamt.Width.Value; y = 0.3; wd = 0.21; ht = ht - 0.3; sgst_per = ReportUtil.AddRectangle("sgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); sgst_per.Style.BorderStyle.Default = BorderStyleEnum.Outset; //sgst_per.Style.BackgroundColor.Color = Color.Firebrick; x = x + sgst_per.Width.Value; y = 0; wd = 0.55; ht = ht + 0.3; sgst_amt = ReportUtil.AddRectangle("sgst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); sgst_amt.Style.BorderStyle.Default = BorderStyleEnum.Outset; //sgst_amt.Style.BackgroundColor.Color = Color.DodgerBlue; x = x + sgst_amt.Width.Value; y = 0.3; wd = 0.2; ht = ht - 0.3; cgst_per = ReportUtil.AddRectangle("cgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); cgst_per.Style.BorderStyle.Default = BorderStyleEnum.Outset; //cgst_per.Style.BackgroundColor.Color = Color.DarkGoldenrod; x = x + cgst_per.Width.Value; y = 0; wd = 0.56; ht = ht + 0.3; cgst_amt = ReportUtil.AddRectangle("cgst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); cgst_amt.Style.BorderStyle.Default = BorderStyleEnum.Outset; // cgst_amt.Style.BackgroundColor.Color = Color.Yellow; cgstwidth = cgst_amt.Width.Value; } else if (Customised.TaxType == Core.IGST) { x = x + taxableamt.Width.Value; y = 0.3; wd = 0.25; ht = ht - 0.3; igst_per = ReportUtil.AddRectangle("igst_per" + sufx, subrect.ReportItems, x, y, wd, ht); igst_per.Style.BorderStyle.Default = BorderStyleEnum.Outset; //igst_per.Style.BackgroundColor.Color = Color.DarkGoldenrod; x = x + igst_per.Width.Value; y = 0; wd = 0.752; ht = ht + 0.3; igst_amt = ReportUtil.AddRectangle("igst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); igst_amt.Style.BorderStyle.Default = BorderStyleEnum.Outset; //igst_amt.Style.BackgroundColor.Color = Color.Yellow; cgstwidth = igst_amt.Width.Value; } x = x + cgstwidth; y = 0; wd = 0.70; ht = ht + 0; sub_total = ReportUtil.AddRectangle("sub_total" + sufx, subrect.ReportItems, x, y, wd, ht); sub_total.Style.BorderStyle.Default = BorderStyleEnum.Outset; //sub_total.Style.BackgroundColor.Color = Color.Blue; #endregion [Lines AREA] // #region [Header ] /// x = slno.Left.Value + 0.01; y = 0.09; wd = slno.Width.Value - 0.03; ht = 0.16; TextboxType lbl_slno = ReportUtil.AddTextbox("lbl_slno" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_slno.Value = "S.No"; lbl_slno.Style.Font("Calibri", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_slno.Style.TextAlign = TextAlignRptEnum.Center; //lbl_slno.Style.BackgroundColor.Color = Color.Salmon; if ((Customised.WithPo == true) && (Customised.WithDc == true)) { x = po.Left.Value + 0.01; y = y + 0; wd = po.Width.Value - 0.03; ht = 0.16; TextboxType lbl_po_no = ReportUtil.AddTextbox("lbl_po_no" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_po_no.Value = "PO.No"; lbl_po_no.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_po_no.Style.TextAlign = TextAlignRptEnum.Center; //lbl_po_no.Style.BackgroundColor.Color = Color.SeaGreen; // x = dc.Left.Value + 0.01; y = y + 0; wd = dc.Width.Value - 0.03; ht = 0.16; TextboxType lbl_dc_no = ReportUtil.AddTextbox("lbl_dc_no" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_dc_no.Value = "DC.No"; lbl_dc_no.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_dc_no.Style.TextAlign = TextAlignRptEnum.Center; // lbl_dc_no.Style.BackgroundColor.Color = Color.Bisque; } x = hsn_code.Left.Value + 0.12; y = 0.03; wd = hsn_code.Width.Value - 0.08; ht = 0.16; TextboxType lbl_hsn = ReportUtil.AddTextbox("lbl_hsn" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_hsn.Value = "HSN"; lbl_hsn.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_hsn.Style.TextAlign = TextAlignRptEnum.Left; //lbl_hsn_code.Style.BackgroundColor.Color = Color.Blue; x = particulars.Left.Value + 0.11; y = y + 0; wd = particulars.Width.Value - 0.13; ht = 0.16; TextboxType lbl_particulars = ReportUtil.AddTextbox("lbl_particulars" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_particulars.Value = "Particulars"; lbl_particulars.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_particulars.Style.TextAlign = TextAlignRptEnum.Left; //lbl_particulars.Style.BackgroundColor.Color = Color.SteelBlue; x = hsn_code.Left.Value + 0.1; y = y + 0.12; wd = hsn_code.Width.Value - 0.08; ht = 0.16; TextboxType lbl_hsn_code = ReportUtil.AddTextbox("lbl_hsn_code" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_hsn_code.Value = "Code"; lbl_hsn_code.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_hsn_code.Style.TextAlign = TextAlignRptEnum.Left; //lbl_hsn_code.Style.BackgroundColor.Color = Color.Blue; if (Customised.WithSizes == true) { x = sizes.Left.Value + 0.01; y = 0.09; wd = sizes.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sizes = ReportUtil.AddTextbox("lbl_sizes" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sizes.Value = "Sizes"; lbl_sizes.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sizes.Style.TextAlign = TextAlignRptEnum.Center; //lbl_sizes.Style.BackgroundColor.Color = Color.Blue; } x = qtys.Left.Value + 0.01; y = 0.09; wd = qtys.Width.Value - 0.03; ht = 0.16; TextboxType lbl_qty = ReportUtil.AddTextbox("lbl_qty" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_qty.Value = "Quantity"; lbl_qty.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_qty.Style.TextAlign = TextAlignRptEnum.Center; //lbl_qty.Style.BackgroundColor.Color = Color.DimGray; /// x = price.Left.Value + 0.01; y = y + 0; wd = price.Width.Value - 0.03; ht = 0.16; TextboxType lbl_price = ReportUtil.AddTextbox("lbl_price" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_price.Value = "Price"; lbl_price.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_price.Style.TextAlign = TextAlignRptEnum.Center; //lbl_price.Style.BackgroundColor.Color = Color.Coral; /// x = taxableamt.Left.Value + 0.01; y = 0.03; wd = taxableamt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_taxableamt = ReportUtil.AddTextbox("lbl_taxableamt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_taxableamt.Value = "Taxable"; lbl_taxableamt.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_taxableamt.Style.TextAlign = TextAlignRptEnum.Center; //lbl_taxableamt.Style.BackgroundColor.Color = Color.Wheat; x = taxableamt.Left.Value + 0.01; y = y + 0.12; wd = taxableamt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_taxableamount = ReportUtil.AddTextbox("lbl_taxableamount" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_taxableamount.Value = "Amt"; lbl_taxableamount.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_taxableamount.Style.TextAlign = TextAlignRptEnum.Center; //lbl_taxableamt.Style.BackgroundColor.Color = Color.Wheat; if (Customised.TaxType == Core.SGST) { x = sgst_per.Left.Value + 0.01; y = 0.02; wd = sgst_per.Width.Value + sgst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sgst = ReportUtil.AddTextbox("lbl_sgst" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sgst.Value = " SGST"; lbl_sgst.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sgst.Style.TextAlign = TextAlignRptEnum.Center; // lbl_sgst.Style.BackgroundColor.Color = Color.Violet; x = sgst_per.Left.Value + 0.03; y = y + 0.1; wd = sgst_per.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sgst_per = ReportUtil.AddTextbox("lbl_sgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sgst_per.Value = " %"; lbl_sgst_per.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sgst_per.Style.TextAlign = TextAlignRptEnum.Left; //lbl_sgst_per.Style.BackgroundColor.Color = Color.Aquamarine; x = sgst_amt.Left.Value + 0.01; y = y + 0.03; wd = sgst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sgst_amt = ReportUtil.AddTextbox("lbl_sgst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sgst_amt.Value = " Amt"; lbl_sgst_amt.Style.Font("Calibri", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sgst_amt.Style.TextAlign = TextAlignRptEnum.Left; //lbl_sgst_amt.Style.BackgroundColor.Color = Color.DimGray; x = cgst_per.Left.Value + 0.01; y = 0.02; wd = cgst_per.Width.Value + cgst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_cgst = ReportUtil.AddTextbox("lbl_cgst" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_cgst.Value = " CGST"; lbl_cgst.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_cgst.Style.TextAlign = TextAlignRptEnum.Center; //lbl_cgst.Style.BackgroundColor.Color = Color.Cyan; x = cgst_per.Left.Value + 0.03; y = y + 0.1; wd = cgst_per.Width.Value - 0.03; ht = 0.16; TextboxType lbl_cgst_per = ReportUtil.AddTextbox("lbl_cgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_cgst_per.Value = " %"; lbl_cgst_per.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_cgst_per.Style.TextAlign = TextAlignRptEnum.Left; //lbl_cgst_per.Style.BackgroundColor.Color = Color.Goldenrod; x = cgst_amt.Left.Value + 0.02; y = y + 0.03; wd = cgst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_cgst_amt = ReportUtil.AddTextbox("lbl_cgst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_cgst_amt.Value = " Amt"; lbl_cgst_amt.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_cgst_amt.Style.TextAlign = TextAlignRptEnum.Left; //lbl_cgst_amt.Style.BackgroundColor.Color = Color.Khaki; } else if (Customised.TaxType == Core.IGST) { x = igst_per.Left.Value + 0.01; y = 0.02; wd = igst_per.Width.Value + igst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_igst = ReportUtil.AddTextbox("lbl_igst" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_igst.Value = " IGST"; lbl_igst.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_igst.Style.TextAlign = TextAlignRptEnum.Center; //lbl_igst.Style.BackgroundColor.Color = Color.Cyan; x = igst_per.Left.Value + 0.03; y = y + 0.1; wd = igst_per.Width.Value - 0.03; ht = 0.16; TextboxType lbl_igst_per = ReportUtil.AddTextbox("lbl_igst_per" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_igst_per.Value = " %"; lbl_igst_per.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_igst_per.Style.TextAlign = TextAlignRptEnum.Left; //lbl_igst_per.Style.BackgroundColor.Color = Color.Goldenrod; x = igst_amt.Left.Value + 0.02; y = y + 0.03; wd = igst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_igst_amt = ReportUtil.AddTextbox("lbl_igst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_igst_amt.Value = " Amt"; lbl_igst_amt.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_igst_amt.Style.TextAlign = TextAlignRptEnum.Left; //lbl_igst_amt.Style.BackgroundColor.Color = Color.Khaki; } x = sub_total.Left.Value + 0.06; y = 0.09; wd = sub_total.Width.Value - 0.09; ht = 0.16; TextboxType lbl_Totalv = ReportUtil.AddTextbox("lbl_Totalv" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_Totalv.Value = "Sub Total"; lbl_Totalv.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_Totalv.Style.TextAlign = TextAlignRptEnum.Center; // lbl_Totalv.Style.BackgroundColor.Color = Color.DodgerBlue; #endregion [Header] // #region [ Detail-Line ] // x = 0; y = 0.4; wd = subrect.Width.Value; ht = 0.03; ListType listDetlLine = ReportUtil.AddList("listDetlLine" + sufx, subrect.ReportItems, x, y, wd, ht); listDetlLine.DataSetName = "MyDataSource_Items"; listDetlLine.Grouping = new GroupingType("group_" + PLabouritems.SL_NO + ""); listDetlLine.Grouping.GroupExpressions.Add("=Fields!" + PLabouritems.SL_NO + ".Value"); //listDetlLine.Style.BackgroundColor.Color = Color.Red; // x = 0; y = 0; wd = 0.55; ht = 0.25; RectangleType listdetails_rect = ReportUtil.AddRectangle("listdetails_rect" + sufx, listDetlLine.ReportItems, x, y, wd, ht); listdetails_rect.Style.BorderStyle.Default = BorderStyleEnum.None; //listdetails_rect.Style.BackgroundColor.Color = Color.Azure; x = slno.Left.Value + 0.01; y = 0; wd = slno.Width.Value - 0.03; ht = ht + 0; TextboxType txt_slno = ReportUtil.AddTextbox("txt_slno" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_slno.Value = "=Fields!" + PLabouritems.SL_NO + ".Value"; txt_slno.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); txt_slno.Style.TextAlign = TextAlignRptEnum.Center; // txt_slno.Style.BackgroundColor.Color = Color.Red; if ((Customised.WithPo == true) && (Customised.WithDc == true)) { x = po.Left.Value + 0.01; y = 0; wd = po.Width.Value - 0.03; ht = ht + 0; TextboxType txt_po_no = ReportUtil.AddTextbox("txt_po_no" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_po_no.Value = "=Fields!" + PLabouritems.PO_NO + ".Value"; txt_po_no.Style.TextAlign = TextAlignRptEnum.Center; txt_po_no.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); // x = dc.Left.Value + 0.01; y = 0; wd = dc.Width.Value - 0.03; ht = ht + 0; TextboxType txt_dc_no = ReportUtil.AddTextbox("txt_dc_no" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_dc_no.Value = "=Fields!" + PLabouritems.DC_NO + ".Value"; txt_dc_no.Style.TextAlign = TextAlignRptEnum.Center; txt_dc_no.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_dc_no.Style.BackgroundColor.Color = Color.Red; } x = hsn_code.Left.Value + 0.01; y = 0; wd = hsn_code.Width.Value - 0.02; ht = ht + 0; TextboxType txt_hsn_code = ReportUtil.AddTextbox("txt_hsn_code" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_hsn_code.Value = "=Fields!HSN_CODE_ID.Value"; txt_hsn_code.Style.TextAlign = TextAlignRptEnum.Center; txt_hsn_code.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_hsn_code.Style.BackgroundColor.Color = Color.Red; x = particulars.Left.Value + 0.05; y = 0; wd = particulars.Width.Value - 0.05; ht = ht + 0; TextboxType txt_product_name = ReportUtil.AddTextbox("txt_product_name" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_product_name.Value = "=Fields!" + PLabouritems.PRODUCT_ID + ".Value"; txt_product_name.Style.TextAlign = TextAlignRptEnum.Left; txt_product_name.CanGrow = true; txt_product_name.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_product_name.Style.BackgroundColor.Color = Color.Red; if (Customised.WithSizes == true) { x = sizes.Left.Value + 0.02; y = 0; wd = sizes.Width.Value - 0.05; ht = ht + 0; TextboxType txt_sizes = ReportUtil.AddTextbox("txt_sizes" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sizes.Value = "=Fields!" + PLabouritems.SIZES + ".Value"; txt_sizes.Style.TextAlign = TextAlignRptEnum.Center; txt_sizes.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); } //txt_product_name.Style.BackgroundColor.Color = Color.Red; x = qtys.Left.Value + 0.02; y = 0; wd = qtys.Width.Value - 0.05; ht = ht + 0; TextboxType txt_qty = ReportUtil.AddTextbox("txt_qty" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_qty.Value = "=Fields!" + PLabouritems.QTY + ".Value"; txt_qty.Style.TextAlign = TextAlignRptEnum.Center; txt_qty.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_qty.Style.BackgroundColor.Color = Color.Red; // x = price.Left.Value + 0.02; y = 0; wd = price.Width.Value - 0.05; ht = ht + 0; TextboxType txt_price = ReportUtil.AddTextbox("txt_price" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_price.Value = "=Fields!" + PLabouritems.PRICE + ".Value"; txt_price.Style.TextAlign = TextAlignRptEnum.Right; txt_price.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_price.Style.BackgroundColor.Color = Color.Red; x = taxableamt.Left.Value + 0.01; y = 0; wd = taxableamt.Width.Value - 0.04; ht = ht + 0; TextboxType txt_taxable = ReportUtil.AddTextbox("txt_taxable" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_taxable.Value = "=Fields!" + PLabouritems.TAXABLEVALUE + ".Value"; txt_taxable.Style.TextAlign = TextAlignRptEnum.Right; txt_taxable.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_taxable.Style.BackgroundColor.Color = Color.Red; if (Customised.TaxType == Core.SGST) { x = sgst_per.Left.Value + 0.01; y = 0; wd = sgst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_sgst_per = ReportUtil.AddTextbox("txt_sgst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sgst_per.Value = "=Fields!" + PLabouritems.SGST_PERCENT + ".Value"; txt_sgst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_sgst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_sgst_per.Style.BackgroundColor.Color = Color.Red; x = sgst_amt.Left.Value; y = 0; wd = sgst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_sgst_amt = ReportUtil.AddTextbox("txt_sgst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sgst_amt.Value = "=Fields!" + PLabouritems.SGST_AMOUNT + ".Value"; txt_sgst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_sgst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_sgst_amt.Style.BackgroundColor.Color = Color.Red; x = cgst_per.Left.Value + 0.01; y = 0; wd = cgst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_cgst_per = ReportUtil.AddTextbox("txt_cgst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_cgst_per.Value = "=Fields!" + PLabouritems.CGST_PERCENT + ".Value"; txt_cgst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_cgst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_cgst_per.Style.BackgroundColor.Color = Color.Red; x = cgst_amt.Left.Value; y = 0; wd = cgst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_cgst_amt = ReportUtil.AddTextbox("txt_cgst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_cgst_amt.Value = "=Fields!" + PLabouritems.CGST_AMOUNT + ".Value"; txt_cgst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_cgst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_cgst_amt.Style.BackgroundColor.Color = Color.ForestGreen; } else if (Customised.TaxType == Core.IGST) { x = igst_per.Left.Value + 0.01; y = 0; wd = igst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_igst_per = ReportUtil.AddTextbox("txt_igst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_igst_per.Value = "=Fields!" + PLabouritems.IGST_PERCENT + ".Value"; txt_igst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_igst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_igst_per.Style.BackgroundColor.Color = Color.Red; x = igst_amt.Left.Value; y = 0; wd = igst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_igst_amt = ReportUtil.AddTextbox("txt_igst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_igst_amt.Value = "=Fields!" + PLabouritems.IGST_AMOUNT + ".Value"; txt_igst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_igst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_igst_amt.Style.BackgroundColor.Color = Color.ForestGreen; } x = sub_total.Left.Value + 0.01; y = 0; wd = sub_total.Width.Value - 0.04; ht = ht + 0; TextboxType txt_amount = ReportUtil.AddTextbox("txt_amount" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_amount.Value = "=Fields!" + PLabouritems.SUB_TOTAL + ".Value"; txt_amount.Style.TextAlign = TextAlignRptEnum.Right; txt_amount.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_amount.Style.BackgroundColor.Color = Color.Red; // #endregion [Detail-Line] // } // fn build details
private static void BuildDetail(BodyType rectWarper) { double x = 0, y = 0, wd = 0, ht = 0; string sufx = ""; /*Now unused. Used before in A4 (i.e 2xA5) print*/ // x = 0; y = 0; wd = 7.65; ht = 0.1; RectangleType subrect = ReportUtil.AddRectangle("manirect" + sufx, rectWarper.ReportItems, x, y, wd, ht); subrect.Style.BorderStyle.Default = BorderStyleEnum.None; //subrect.Style.BackgroundColor.Color = Color.Red; #region [HEADING AREA] // x = 0; y = 0; wd = subrect.Width.Value; ht = 0.3; RectangleType heading = ReportUtil.AddRectangle("heading" + sufx, subrect.ReportItems, x, y, wd, ht); heading.Style.BorderStyle.Default = BorderStyleEnum.Outset; //heading.Style.BackgroundColor.Color = Color.Orange; //x = 6.2; y = 0; wd = 0.03; ht = 0.3; //RectangleType heading_line = ReportUtil.AddRectangle("heading_line" + sufx, subrect.ReportItems, x, y, wd, ht); //heading_line.Style.BorderStyle.Default = BorderStyleEnum.None; //heading_line.Style.BorderStyle.Left = BorderStyleEnum.Outset; ////heading_line.Style.BackgroundColor.Color = Color.Orange; // #endregion [HEADING AREA] #region [Lines AREA] x = 0; y = 0; wd = 0.23; ht = 5; RectangleType slno = ReportUtil.AddRectangle("slno" + sufx, subrect.ReportItems, x, y, wd, ht); slno.Style.BorderStyle.Default = BorderStyleEnum.Outset; //slno.Style.BackgroundColor.Color = Color.MistyRose; x = slno.Width.Value; y = 0; wd = 0.5; ht = ht + 0; RectangleType po = ReportUtil.AddRectangle("po" + sufx, subrect.ReportItems, x, y, wd, ht); po.Style.BorderStyle.Default = BorderStyleEnum.Outset; //po.Style.BackgroundColor.Color = Color.Green; x = x + po.Width.Value; y = 0; wd = 0.5; ht = ht + 0; RectangleType dc = ReportUtil.AddRectangle("dc" + sufx, subrect.ReportItems, x, y, wd, ht); dc.Style.BorderStyle.Default = BorderStyleEnum.Outset; //dc.Style.BackgroundColor.Color = Color.Blue; x = x + dc.Width.Value; y = 0; wd = 2.02; ht = ht + 0; RectangleType particulars = ReportUtil.AddRectangle("particulars" + sufx, subrect.ReportItems, x, y, wd, ht); particulars.Style.BorderStyle.Default = BorderStyleEnum.Outset; //particulars.Style.BackgroundColor.Color = Color.FloralWhite; x = x + particulars.Width.Value; y = 0; wd = 0.7; ht = ht + 0; RectangleType hsn_code = ReportUtil.AddRectangle("hsn_code" + sufx, subrect.ReportItems, x, y, wd, ht); hsn_code.Style.BorderStyle.Default = BorderStyleEnum.Outset; //hsn_code.Style.BackgroundColor.Color = Color.Chocolate; x = x + hsn_code.Width.Value; y = 0; wd = 0.6; ht = ht + 0; RectangleType qtys = ReportUtil.AddRectangle("qtys" + sufx, subrect.ReportItems, x, y, wd, ht); qtys.Style.BorderStyle.Default = BorderStyleEnum.Outset; //qtys.Style.BackgroundColor.Color = Color.SaddleBrown; x = x + qtys.Width.Value; y = 0; wd = 0.45; ht = ht + 0; RectangleType price = ReportUtil.AddRectangle("price" + sufx, subrect.ReportItems, x, y, wd, ht); price.Style.BorderStyle.Default = BorderStyleEnum.Outset; //price.Style.BackgroundColor.Color = Color.Aquamarine; x = x + price.Width.Value; y = 0; wd = 0.75; ht = ht + 0; RectangleType taxableamt = ReportUtil.AddRectangle("taxableamt" + sufx, subrect.ReportItems, x, y, wd, ht); taxableamt.Style.BorderStyle.Default = BorderStyleEnum.Outset; //amount.Style.BackgroundColor.Color = Color.Green; x = x + taxableamt.Width.Value; y = 0.3; wd = 0.25; ht = ht - 0.3; RectangleType icgst_per = ReportUtil.AddRectangle("icgst_per" + sufx, subrect.ReportItems, x, y, wd, ht); icgst_per.Style.BorderStyle.Default = BorderStyleEnum.Outset; //igst_per.Style.BackgroundColor.Color = Color.DarkGoldenrod; x = x + icgst_per.Width.Value; y = 0.3; wd = 0.75; ht = ht + 0; RectangleType igst_amt = ReportUtil.AddRectangle("igst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); igst_amt.Style.BorderStyle.Default = BorderStyleEnum.Outset; //igst_amt.Style.BackgroundColor.Color = Color.Yellow; x = x + igst_amt.Width.Value; y = 0; wd = 0.90; ht = ht + 0.3; RectangleType subtotal = ReportUtil.AddRectangle("subtotal" + sufx, subrect.ReportItems, x, y, wd, ht); subtotal.Style.BorderStyle.Default = BorderStyleEnum.Outset; //subtotal.Style.BackgroundColor.Color = Color.Blue; #endregion [Lines AREA] #region [Header ] x = slno.Left.Value + 0.01; y = 0.09; wd = slno.Width.Value - 0.03; ht = 0.16; TextboxType lbl_slno = ReportUtil.AddTextbox("lbl_slno" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_slno.Value = "S.No"; lbl_slno.Style.Font("Calibri", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_slno.Style.TextAlign = TextAlignRptEnum.Center; //lbl_slno.Style.BackgroundColor.Color = Color.Salmon; x = po.Left.Value + 0.01; y = y + 0; wd = po.Width.Value - 0.03; ht = 0.16; TextboxType lbl_po_no = ReportUtil.AddTextbox("lbl_po_no" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_po_no.Value = "PO.No"; lbl_po_no.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_po_no.Style.TextAlign = TextAlignRptEnum.Center; //lbl_po_no.Style.BackgroundColor.Color = Color.SeaGreen; x = dc.Left.Value + 0.01; y = y + 0; wd = dc.Width.Value - 0.03; ht = 0.16; TextboxType lbl_dc_no = ReportUtil.AddTextbox("lbl_dc_no" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_dc_no.Value = "DC.No"; lbl_dc_no.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_dc_no.Style.TextAlign = TextAlignRptEnum.Center; //lbl_dc_no.Style.BackgroundColor.Color = Color.Bisque; x = particulars.Left.Value + 0.11; y = y + 0; wd = particulars.Width.Value - 0.13; ht = 0.16; TextboxType lbl_particulars = ReportUtil.AddTextbox("lbl_particulars" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_particulars.Value = "Particulars"; lbl_particulars.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_particulars.Style.TextAlign = TextAlignRptEnum.Left; //lbl_particulars.Style.BackgroundColor.Color = Color.SteelBlue; x = hsn_code.Left.Value + 0.12; y = y + 0; wd = hsn_code.Width.Value - 0.08; ht = 0.16; TextboxType lbl_hsn = ReportUtil.AddTextbox("lbl_hsn" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_hsn.Value = "HSN Code"; lbl_hsn.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_hsn.Style.TextAlign = TextAlignRptEnum.Left; //lbl_hsn_code.Style.BackgroundColor.Color = Color.Blue; //x = hsn_code.Left.Value + 0.1; y = y + 0.12; wd = hsn_code.Width.Value - 0.08; ht = 0.16; //TextboxType lbl_hsn_code = ReportUtil.AddTextbox("lbl_hsn_code" + sufx, subrect.ReportItems, x, y, wd, ht); //lbl_hsn_code.Value = "Code"; //lbl_hsn_code.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); //lbl_hsn_code.Style.TextAlign = TextAlignRptEnum.Left; ////lbl_hsn_code.Style.BackgroundColor.Color = Color.Blue; x = qtys.Left.Value + 0.01; y = 0.09; wd = qtys.Width.Value - 0.03; ht = 0.16; TextboxType lbl_qty = ReportUtil.AddTextbox("lbl_qty" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_qty.Value = "Quantity"; lbl_qty.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_qty.Style.TextAlign = TextAlignRptEnum.Center; //lbl_qty.Style.BackgroundColor.Color = Color.DimGray; x = price.Left.Value + 0.01; y = y + 0; wd = price.Width.Value - 0.03; ht = 0.16; TextboxType lbl_price = ReportUtil.AddTextbox("lbl_price" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_price.Value = "Price"; lbl_price.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_price.Style.TextAlign = TextAlignRptEnum.Center; //lbl_price.Style.BackgroundColor.Color = Color.Coral; x = taxableamt.Left.Value + 0.01; y = 0.03; wd = taxableamt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_taxableamt = ReportUtil.AddTextbox("lbl_taxableamt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_taxableamt.Value = "Taxable"; lbl_taxableamt.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_taxableamt.Style.TextAlign = TextAlignRptEnum.Center; //lbl_taxableamt.Style.BackgroundColor.Color = Color.Wheat; x = taxableamt.Left.Value + 0.01; y = y + 0.12; wd = taxableamt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_taxableamount = ReportUtil.AddTextbox("lbl_taxableamount" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_taxableamount.Value = "Amt"; lbl_taxableamount.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_taxableamount.Style.TextAlign = TextAlignRptEnum.Center; //lbl_taxableamt.Style.BackgroundColor.Color = Color.Wheat; x = icgst_per.Left.Value + 0.01; y = 0.02; wd = icgst_per.Width.Value + igst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_igst = ReportUtil.AddTextbox("lbl_igst" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_igst.Value = " IGST"; lbl_igst.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_igst.Style.TextAlign = TextAlignRptEnum.Center; //lbl_igst.Style.BackgroundColor.Color = Color.Cyan; x = icgst_per.Left.Value + 0.03; y = y + 0.1; wd = icgst_per.Width.Value - 0.03; ht = 0.16; TextboxType lbl_igst_per = ReportUtil.AddTextbox("lbl_igst_per" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_igst_per.Value = " %"; lbl_igst_per.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_igst_per.Style.TextAlign = TextAlignRptEnum.Left; //lbl_igst_per.Style.BackgroundColor.Color = Color.Goldenrod; x = igst_amt.Left.Value + 0.02; y = y + 0.03; wd = igst_amt.Width.Value - 0.03; ht = 0.16; TextboxType lbl_igst_amt = ReportUtil.AddTextbox("lbl_igst_amt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_igst_amt.Value = " Amt"; lbl_igst_amt.Style.Font("Calibri", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_igst_amt.Style.TextAlign = TextAlignRptEnum.Left; //lbl_igst_amt.Style.BackgroundColor.Color = Color.Khaki; x = subtotal.Left.Value + 0.06; y = 0.09; wd = subtotal.Width.Value - 0.09; ht = 0.16; TextboxType lbl_subtotal = ReportUtil.AddTextbox("lbl_subtotal" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_subtotal.Value = "Sub Total"; lbl_subtotal.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_subtotal.Style.TextAlign = TextAlignRptEnum.Center; //lbl_Totalv.Style.BackgroundColor.Color = Color.DodgerBlue; #endregion [Header] #region [ Detail-Line ] x = 0; y = 0.4; wd = subrect.Width.Value; ht = 0.03; ListType listDetlLine = ReportUtil.AddList("listDetlLine" + sufx, subrect.ReportItems, x, y, wd, ht); listDetlLine.DataSetName = "MyDataSource_Items"; listDetlLine.Grouping = new GroupingType("group_" + PPurchaseitems.SL_NO + ""); listDetlLine.Grouping.GroupExpressions.Add("=Fields!" + PPurchaseitems.SL_NO + ".Value"); //listDetlLine.Style.BackgroundColor.Color = Color.Red; x = 0; y = 0; wd = 0.55; ht = 0.25; RectangleType listdetails_rect = ReportUtil.AddRectangle("listdetails_rect" + sufx, listDetlLine.ReportItems, x, y, wd, ht); listdetails_rect.Style.BorderStyle.Default = BorderStyleEnum.None; //listdetails_rect.Style.BackgroundColor.Color = Color.Azure; x = slno.Left.Value + 0.01; y = 0; wd = slno.Width.Value - 0.03; ht = ht + 0; TextboxType txt_slno = ReportUtil.AddTextbox("txt_slno" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_slno.Value = "=Fields!" + PPurchaseitems.SL_NO + ".Value"; txt_slno.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); txt_slno.Style.TextAlign = TextAlignRptEnum.Center; //txt_slno.Style.BackgroundColor.Color = Color.Red; x = po.Left.Value + 0.01; y = 0; wd = po.Width.Value - 0.03; ht = ht + 0; TextboxType txt_po_no = ReportUtil.AddTextbox("txt_po_no" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_po_no.Value = "=Fields!" + PPurchaseitems.PO_ID + ".Value"; txt_po_no.Style.TextAlign = TextAlignRptEnum.Center; txt_po_no.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); x = dc.Left.Value + 0.01; y = 0; wd = dc.Width.Value - 0.03; ht = ht + 0; TextboxType txt_dc_no = ReportUtil.AddTextbox("txt_dc_no" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_dc_no.Value = "=Fields!" + PPurchaseitems.DC_ID + ".Value"; txt_dc_no.Style.TextAlign = TextAlignRptEnum.Center; txt_dc_no.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_dc_no.Style.BackgroundColor.Color = Color.Red; x = particulars.Left.Value + 0.05; y = 0; wd = particulars.Width.Value - 0.05; ht = ht + 0; TextboxType txt_product_name = ReportUtil.AddTextbox("txt_product_name" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_product_name.Value = "=Fields!" + PPurchaseitems.PRODUCT_ID + ".Value"; txt_product_name.Style.TextAlign = TextAlignRptEnum.Left; txt_product_name.CanGrow = true; txt_product_name.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_product_name.Style.BackgroundColor.Color = Color.Red; x = hsn_code.Left.Value + 0.01; y = 0; wd = hsn_code.Width.Value - 0.02; ht = ht + 0; TextboxType txt_hsn_code = ReportUtil.AddTextbox("txt_hsn_code" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_hsn_code.Value = "=Fields!" + PPurchaseitems.HSN_CODE_ID + ".Value"; txt_hsn_code.Style.TextAlign = TextAlignRptEnum.Center; txt_hsn_code.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_hsn_code.Style.BackgroundColor.Color = Color.Red; x = qtys.Left.Value + 0.02; y = 0; wd = qtys.Width.Value - 0.05; ht = ht + 0; TextboxType txt_qty = ReportUtil.AddTextbox("txt_qty" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_qty.Value = "=Fields!" + PPurchaseitems.QTY + ".Value"; txt_qty.Style.TextAlign = TextAlignRptEnum.Center; txt_qty.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_qty.Style.BackgroundColor.Color = Color.Red; x = price.Left.Value + 0.02; y = 0; wd = price.Width.Value - 0.05; ht = ht + 0; TextboxType txt_price = ReportUtil.AddTextbox("txt_price" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_price.Value = "=Fields!" + PPurchaseitems.PRICE + ".Value"; txt_price.Style.TextAlign = TextAlignRptEnum.Right; txt_price.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_price.Style.BackgroundColor.Color = Color.Red; x = taxableamt.Left.Value + 0.01; y = 0; wd = taxableamt.Width.Value - 0.04; ht = ht + 0; TextboxType txt_taxable = ReportUtil.AddTextbox("txt_taxable" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_taxable.Value = "=Fields!" + PPurchaseitems.TAXABLEVALUE + ".Value"; txt_taxable.Style.TextAlign = TextAlignRptEnum.Right; txt_taxable.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_taxable.Style.BackgroundColor.Color = Color.Red; x = icgst_per.Left.Value + 0.01; y = 0; wd = icgst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_igst_per = ReportUtil.AddTextbox("txt_cgst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_igst_per.Value = "=Fields!" + PPurchaseitems.IGST_PERCENT + ".Value"; txt_igst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_igst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_igst_per.Style.BackgroundColor.Color = Color.Red; x = igst_amt.Left.Value; y = 0; wd = igst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_igst_amt = ReportUtil.AddTextbox("txt_cgst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_igst_amt.Value = "=Fields!" + PPurchaseitems.IGST_AMOUNT + ".Value"; txt_igst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_igst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_igst_amt.Style.BackgroundColor.Color = Color.ForestGreen; x = subtotal.Left.Value + 0.01; y = 0; wd = subtotal.Width.Value - 0.04; ht = ht + 0; TextboxType txt_subtotal = ReportUtil.AddTextbox("txt_amount" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_subtotal.Value = "=Fields!" + PPurchaseitems.SUB_TOTAL + ".Value"; txt_subtotal.Style.TextAlign = TextAlignRptEnum.Right; txt_subtotal.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_subtotal.Style.BackgroundColor.Color = Color.Red; #endregion [Detail-Line] }
private static void BuildDetail(BodyType rectWarper) { double x = 0, y = 0, wd = 0, ht = 0; string sufx = ""; /*Now unused. Used before in A4 (i.e 2xA5) print*/ // x = 0; y = 0; wd = 7.65; ht = 0.1; RectangleType subrect = ReportUtil.AddRectangle("manirect" + sufx, rectWarper.ReportItems, x, y, wd, ht); subrect.Style.BorderStyle.Default = BorderStyleEnum.None; //subrect.Style.BackgroundColor.Color = Color.Red; // #region [HEADING AREA] // x = 0; y = 0; wd = subrect.Width.Value; ht = 0.3; RectangleType heading = ReportUtil.AddRectangle("heading" + sufx, subrect.ReportItems, x, y, wd, ht); heading.Style.BorderStyle.Default = BorderStyleEnum.None; heading.Style.BorderStyle.Top = BorderStyleEnum.Outset; heading.Style.BorderStyle.Bottom = BorderStyleEnum.Outset; //heading.Style.BackgroundColor.Color = Color.Orange; #endregion [HEADING AREA] // #region [Lines AREA] x = 0; y = 0; wd = 0.23; ht = 3; RectangleType slno = ReportUtil.AddRectangle("slno" + sufx, subrect.ReportItems, x, y, wd, ht); slno.Style.BorderStyle.Default = BorderStyleEnum.None; //slno.Style.BackgroundColor.Color = Color.MistyRose; x = x + slno.Width.Value; y = 0; wd = 4.02; ht = ht + 0; RectangleType particulars = ReportUtil.AddRectangle("particulars" + sufx, subrect.ReportItems, x, y, wd, ht); particulars.Style.BorderStyle.Default = BorderStyleEnum.None; //particulars.Style.BackgroundColor.Color = Color.FloralWhite; // x = x + particulars.Width.Value; y = 0; wd = 0.8; ht = ht + 0; RectangleType sizes = ReportUtil.AddRectangle("sizes" + sufx, subrect.ReportItems, x, y, wd, ht); sizes.Style.BorderStyle.Default = BorderStyleEnum.None; //sizes.Style.BackgroundColor.Color = Color.SaddleBrown; // x = x + sizes.Width.Value; y = 0; wd = 0.9; ht = ht + 0; RectangleType qtys = ReportUtil.AddRectangle("qtys" + sufx, subrect.ReportItems, x, y, wd, ht); qtys.Style.BorderStyle.Default = BorderStyleEnum.None; //qtys.Style.BackgroundColor.Color = Color.SaddleBrown; // x = x + qtys.Width.Value; y = 0; wd = 0.8; ht = ht + 0; RectangleType price = ReportUtil.AddRectangle("price" + sufx, subrect.ReportItems, x, y, wd, ht); price.Style.BorderStyle.Default = BorderStyleEnum.None; //price.Style.BackgroundColor.Color = Color.Aquamarine; // x = x + price.Width.Value; y = 0; wd = 0.9; ht = ht + 0; RectangleType taxableamt = ReportUtil.AddRectangle("taxableamt" + sufx, subrect.ReportItems, x, y, wd, ht); taxableamt.Style.BorderStyle.Default = BorderStyleEnum.None; //amount.Style.BackgroundColor.Color = Color.Green; // #endregion [Lines AREA] #region [Header ] /// x = slno.Left.Value + 0.01; y = 0.09; wd = slno.Width.Value - 0.03; ht = 0.16; TextboxType lbl_slno = ReportUtil.AddTextbox("lbl_slno" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_slno.Value = "S.No"; lbl_slno.Style.Font("Calibri", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_slno.Style.TextAlign = TextAlignRptEnum.Center; //lbl_slno.Style.BackgroundColor.Color = Color.Salmon; x = particulars.Left.Value + 0.11; y = y + 0; wd = particulars.Width.Value - 0.13; ht = 0.16; TextboxType lbl_particulars = ReportUtil.AddTextbox("lbl_particulars" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_particulars.Value = "Particulars"; lbl_particulars.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_particulars.Style.TextAlign = TextAlignRptEnum.Left; //lbl_particulars.Style.BackgroundColor.Color = Color.SteelBlue; x = sizes.Left.Value + 0.01; y = 0.09; wd = sizes.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sizes = ReportUtil.AddTextbox("lbl_sizes" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sizes.Value = "Sizes"; lbl_sizes.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sizes.Style.TextAlign = TextAlignRptEnum.Center; //lbl_sizes.Style.BackgroundColor.Color = Color.Blue; x = qtys.Left.Value + 0.01; y = 0.09; wd = qtys.Width.Value - 0.03; ht = 0.16; TextboxType lbl_qty = ReportUtil.AddTextbox("lbl_qty" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_qty.Value = "Quantity"; lbl_qty.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_qty.Style.TextAlign = TextAlignRptEnum.Center; //lbl_qty.Style.BackgroundColor.Color = Color.DimGray; /// x = price.Left.Value + 0.01; y = y + 0; wd = price.Width.Value - 0.01; ht = 0.16; TextboxType lbl_price = ReportUtil.AddTextbox("lbl_price" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_price.Value = "Price"; lbl_price.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_price.Style.TextAlign = TextAlignRptEnum.Center; //lbl_price.Style.BackgroundColor.Color = Color.Coral; /// x = taxableamt.Left.Value + 0.01; y = y + 0; wd = price.Width.Value - 0.01; ht = 0.16; TextboxType lbl_taxableamt = ReportUtil.AddTextbox("lbl_taxableamt" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_taxableamt.Value = "Amount"; lbl_taxableamt.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_taxableamt.Style.TextAlign = TextAlignRptEnum.Center; //lbl_taxableamt.Style.BackgroundColor.Color = Color.Coral; /// #endregion [Header] #region [ Detail-Line ] // x = 0; y = 0.4; wd = subrect.Width.Value; ht = 0.03; ListType listDetlLine = ReportUtil.AddList("listDetlLine" + sufx, subrect.ReportItems, x, y, wd, ht); listDetlLine.DataSetName = "MyDataSource_Items"; listDetlLine.Grouping = new GroupingType("group_" + PQuotationitems.SL_NO + ""); listDetlLine.Grouping.GroupExpressions.Add("=Fields!" + PQuotationitems.SL_NO + ".Value"); //listDetlLine.Style.BackgroundColor.Color = Color.Red; // x = 0; y = 0; wd = 0.55; ht = 0.25; RectangleType listdetails_rect = ReportUtil.AddRectangle("listdetails_rect" + sufx, listDetlLine.ReportItems, x, y, wd, ht); listdetails_rect.Style.BorderStyle.Default = BorderStyleEnum.None; //listdetails_rect.Style.BackgroundColor.Color = Color.Azure; // x = slno.Left.Value + 0.01; y = 0; wd = slno.Width.Value - 0.03; ht = ht + 0; TextboxType txt_slno = ReportUtil.AddTextbox("txt_slno" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_slno.Value = "=Fields!" + PQuotationitems.SL_NO + ".Value"; txt_slno.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); txt_slno.Style.TextAlign = TextAlignRptEnum.Center; // txt_slno.Style.BackgroundColor.Color = Color.Red; // x = particulars.Left.Value + 0.05; y = 0; wd = particulars.Width.Value - 0.05; ht = ht + 0; TextboxType txt_product_name = ReportUtil.AddTextbox("txt_product_name" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_product_name.Value = "=Fields!" + PQuotationitems.PRODUCT_ID + ".Value"; txt_product_name.Style.TextAlign = TextAlignRptEnum.Left; txt_product_name.CanGrow = true; txt_product_name.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_product_name.Style.BackgroundColor.Color = Color.Red; x = sizes.Left.Value + 0.01; y = 0; wd = sizes.Width.Value - 0.01; ht = ht + 0; TextboxType txt_sizes = ReportUtil.AddTextbox("txt_sizes" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sizes.Value = "=Fields!" + PQuotationitems.SIZES_ID + ".Value"; txt_sizes.Style.TextAlign = TextAlignRptEnum.Center; txt_sizes.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_sizes.Style.BackgroundColor.Color = Color.Red; //txt_product_name.Style.BackgroundColor.Color = Color.Red; // x = qtys.Left.Value + 0.02; y = 0; wd = qtys.Width.Value - 0.05; ht = ht + 0; TextboxType txt_qty = ReportUtil.AddTextbox("txt_qty" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_qty.Value = "=Fields!" + PQuotationitems.QTY + ".Value"; txt_qty.Style.TextAlign = TextAlignRptEnum.Center; txt_qty.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); // txt_qty.Style.BackgroundColor.Color = Color.Red; // x = price.Left.Value + 0.02; y = 0; wd = price.Width.Value - 0.05; ht = ht + 0; TextboxType txt_price = ReportUtil.AddTextbox("txt_price" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_price.Value = "=Fields!" + PQuotationitems.PRICE + ".Value"; txt_price.Style.TextAlign = TextAlignRptEnum.Right; txt_price.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_price.Style.BackgroundColor.Color = Color.Red; x = taxableamt.Left.Value + 0.01; y = 0; wd = taxableamt.Width.Value - 0.04; ht = ht + 0; TextboxType txt_taxable = ReportUtil.AddTextbox("txt_taxable" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_taxable.Value = "=Fields!" + PQuotationitems.TAXABLEVALUE + ".Value"; txt_taxable.Style.TextAlign = TextAlignRptEnum.Right; txt_taxable.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); //txt_taxable.Style.BackgroundColor.Color = Color.Red; #endregion [Detail-Line] } // fn build details
private static void Sub_Details(CXSubRectangles rct) { RectangleType subrect = rct.subrect; string sufx = rct.sufx; double x = 0, y = 0, wd = 0.23, ht = Customised.SubReportHeight; x = 0; y = 0.4; wd = subrect.Width.Value; ht = 0.03; ListType listDetlLine = ReportUtil.AddList("listDetlLine" + sufx, subrect.ReportItems, x, y, wd, ht); listDetlLine.DataSetName = "MyDataSource_Items"; listDetlLine.Grouping = new GroupingType("group_" + PInvoiceitems.SL_NO + ""); listDetlLine.Grouping.GroupExpressions.Add("=Fields!" + PInvoiceitems.SL_NO + ".Value"); //listDetlLine.Style.BackgroundColor.Color = Color.Red; // x = 0; y = 0; wd = 0.55; ht = 0.25; RectangleType listdetails_rect = ReportUtil.AddRectangle("listdetails_rect" + sufx, listDetlLine.ReportItems, x, y, wd, ht); listdetails_rect.Style.BorderStyle.Default = BorderStyleEnum.None; //listdetails_rect.Style.BackgroundColor.Color = Color.Azure; x = rct.Slno.Left.Value + 0.01; y = 0; wd = rct.Slno.Width.Value - 0.03; ht = ht + 0; TextboxType txt_slno = ReportUtil.AddTextbox("txt_slno" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_slno.Value = "=Fields!" + PInvoiceitems.SL_NO + ".Value"; txt_slno.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); txt_slno.Style.TextAlign = TextAlignRptEnum.Center; if (Customised.WithPo) { x = rct.Po.Left.Value + 0.01; y = 0; wd = rct.Po.Width.Value - 0.03; ht = ht + 0; TextboxType txt_po_no = ReportUtil.AddTextbox("txt_po_no" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_po_no.Value = "=Fields!" + PInvoiceitems.PO_NO + ".Value"; txt_po_no.Style.TextAlign = TextAlignRptEnum.Center; txt_po_no.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); } if (Customised.WithDc) { x = rct.Dc.Left.Value + 0.01; y = 0; wd = rct.Dc.Width.Value - 0.03; ht = ht + 0; TextboxType txt_dc_no = ReportUtil.AddTextbox("txt_dc_no" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_dc_no.Value = "=Fields!" + PInvoiceitems.DC_NO + ".Value"; txt_dc_no.Style.TextAlign = TextAlignRptEnum.Center; txt_dc_no.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal); } x = rct.Hsn_code.Left.Value + 0.01; y = 0; wd = rct.Hsn_code.Width.Value - 0.02; ht = ht + 0; TextboxType txt_hsn_code = ReportUtil.AddTextbox("txt_hsn_code" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_hsn_code.Value = "=Fields!HSN_CODE_ID.Value"; txt_hsn_code.Style.TextAlign = TextAlignRptEnum.Center; txt_hsn_code.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); x = rct.Particulars.Left.Value + 0.05; y = 0; wd = rct.Particulars.Width.Value - 0.05; ht = ht + 0; TextboxType txt_product_name = ReportUtil.AddTextbox("txt_product_name" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_product_name.Value = "=Fields!" + PInvoiceitems.PRODUCT_ID + ".Value"; txt_product_name.Style.TextAlign = TextAlignRptEnum.Left; txt_product_name.CanGrow = true; txt_product_name.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); if (Customised.WithSizes) { x = rct.Sizes.Left.Value + 0.02; y = 0; wd = rct.Sizes.Width.Value - 0.05; ht = ht + 0; TextboxType txt_sizes = ReportUtil.AddTextbox("txt_sizes" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sizes.Value = "=Fields!" + PInvoiceitems.SIZES + ".Value"; txt_sizes.Style.TextAlign = TextAlignRptEnum.Center; txt_sizes.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); } if (Customised.WithColours) { x = rct.Colours.Left.Value + 0.02; y = 0; wd = rct.Colours.Width.Value - 0.05; ht = ht + 0; TextboxType txt_colours = ReportUtil.AddTextbox("txt_colours" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_colours.Value = "=Fields!" + PInvoiceitems.COLOURS + ".Value"; txt_colours.Style.TextAlign = TextAlignRptEnum.Center; txt_colours.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); } x = rct.Qtys.Left.Value + 0.02; y = 0; wd = rct.Qtys.Width.Value - 0.05; ht = ht + 0; TextboxType txt_qty = ReportUtil.AddTextbox("txt_qty" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_qty.Value = "=Fields!" + PInvoiceitems.QTY + ".Value"; txt_qty.Style.TextAlign = TextAlignRptEnum.Center; txt_qty.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); x = rct.Price.Left.Value + 0.02; y = 0; wd = rct.Price.Width.Value - 0.05; ht = ht + 0; TextboxType txt_price = ReportUtil.AddTextbox("txt_price" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_price.Value = "=Fields!" + PInvoiceitems.PRICE + ".Value"; txt_price.Style.TextAlign = TextAlignRptEnum.Right; txt_price.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); x = rct.Taxableamt.Left.Value + 0.01; y = 0; wd = rct.Taxableamt.Width.Value - 0.04; ht = ht + 0; TextboxType txt_taxable = ReportUtil.AddTextbox("txt_taxable" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_taxable.Value = "=Fields!" + PInvoiceitems.TAXABLEVALUE + ".Value"; txt_taxable.Style.TextAlign = TextAlignRptEnum.Right; txt_taxable.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); if (Customised.TaxType == Core.SGST) { x = rct.Sgst_per.Left.Value + 0.01; y = 0; wd = rct.Sgst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_sgst_per = ReportUtil.AddTextbox("txt_sgst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sgst_per.Value = "=Fields!" + PInvoiceitems.SGST_PERCENT + ".Value"; txt_sgst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_sgst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); x = rct.Sgst_amt.Left.Value; y = 0; wd = rct.Sgst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_sgst_amt = ReportUtil.AddTextbox("txt_sgst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sgst_amt.Value = "=Fields!" + PInvoiceitems.SGST_AMOUNT + ".Value"; txt_sgst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_sgst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); x = rct.Cgst_per.Left.Value + 0.01; y = 0; wd = rct.Cgst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_cgst_per = ReportUtil.AddTextbox("txt_cgst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_cgst_per.Value = "=Fields!" + PInvoiceitems.CGST_PERCENT + ".Value"; txt_cgst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_cgst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); x = rct.Cgst_amt.Left.Value; y = 0; wd = rct.Cgst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_cgst_amt = ReportUtil.AddTextbox("txt_cgst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_cgst_amt.Value = "=Fields!" + PInvoiceitems.CGST_AMOUNT + ".Value"; txt_cgst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_cgst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); } else if (Customised.TaxType == Core.IGST) { x = rct.Igst_per.Left.Value + 0.01; y = 0; wd = rct.Igst_per.Width.Value - 0.04; ht = ht + 0; TextboxType txt_igst_per = ReportUtil.AddTextbox("txt_igst_per" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_igst_per.Value = "=Fields!" + PInvoiceitems.IGST_PERCENT + ".Value"; txt_igst_per.Style.TextAlign = TextAlignRptEnum.Center; txt_igst_per.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); x = rct.Igst_amt.Left.Value; y = 0; wd = rct.Igst_amt.Width.Value - 0.03; ht = ht + 0; TextboxType txt_igst_amt = ReportUtil.AddTextbox("txt_igst_amt" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_igst_amt.Value = "=Fields!" + PInvoiceitems.IGST_AMOUNT + ".Value"; txt_igst_amt.Style.TextAlign = TextAlignRptEnum.Right; txt_igst_amt.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); } x = rct.Sub_total.Left.Value + 0.01; y = 0; wd = rct.Sub_total.Width.Value - 0.04; ht = ht + 0; TextboxType txt_amount = ReportUtil.AddTextbox("txt_amount" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_amount.Value = "=Fields!" + PInvoiceitems.SUB_TOTAL + ".Value"; txt_amount.Style.TextAlign = TextAlignRptEnum.Right; txt_amount.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal); }
private static void BuildDetail(BodyType rectWarper) { double x = 0, y = 0, wd = 0, ht = 0; string sufx = ""; /*Now unused. Used before in A4 (i.e 2xA5) print*/ // x = 0; y = 0; wd = 7.65; ht = 0.1; RectangleType subrect = ReportUtil.AddRectangle("manirect" + sufx, rectWarper.ReportItems, x, y, wd, ht); subrect.Style.BorderStyle.Default = BorderStyleEnum.None; //subrect.Style.BackgroundColor.Color = Color.Red; // #region [HEADING AREA] // x = 0; y = 0; wd = subrect.Width.Value; ht = 0.3; RectangleType heading = ReportUtil.AddRectangle("heading" + sufx, subrect.ReportItems, x, y, wd, ht); heading.Style.BorderStyle.Default = BorderStyleEnum.None; heading.Style.BorderStyle.Top = BorderStyleEnum.Outset; heading.Style.BorderStyle.Bottom = BorderStyleEnum.Outset; //heading.Style.BackgroundColor.Color = Color.Orange; #endregion [HEADING AREA] // #region [Lines AREA] x = 0; y = 0; wd = 0.23; ht = 3; RectangleType slno = ReportUtil.AddRectangle("slno" + sufx, subrect.ReportItems, x, y, wd, ht); slno.Style.BorderStyle.Default = BorderStyleEnum.None; //slno.Style.BackgroundColor.Color = Color.MistyRose; x += slno.Width.Value; y = 0; wd = 0.8; ht += 0; RectangleType styles = ReportUtil.AddRectangle("styles" + sufx, subrect.ReportItems, x, y, wd, ht); styles.Style.BorderStyle.Default = BorderStyleEnum.None; //styles.Style.BackgroundColor.Color = Color.SaddleBrown; x += styles.Width.Value; y = 0; wd = 0.8; ht += 0; RectangleType article = ReportUtil.AddRectangle("article" + sufx, subrect.ReportItems, x, y, wd, ht); article.Style.BorderStyle.Default = BorderStyleEnum.None; //article.Style.BackgroundColor.Color = Color.Red; x = x + article.Width.Value; y = 0; wd = 3; ht = ht + 0; RectangleType particulars = ReportUtil.AddRectangle("particulars" + sufx, subrect.ReportItems, x, y, wd, ht); particulars.Style.BorderStyle.Default = BorderStyleEnum.None; //particulars.Style.BackgroundColor.Color = Color.FloralWhite; // x = x + particulars.Width.Value; y = 0; wd = 0.8; ht = ht + 0; RectangleType sizes = ReportUtil.AddRectangle("sizes" + sufx, subrect.ReportItems, x, y, wd, ht); sizes.Style.BorderStyle.Default = BorderStyleEnum.None; //sizes.Style.BackgroundColor.Color = Color.SaddleBrown; x = x + sizes.Width.Value; y = 0; wd = 0.8; ht = ht + 0; RectangleType colours = ReportUtil.AddRectangle("colours" + sufx, subrect.ReportItems, x, y, wd, ht); colours.Style.BorderStyle.Default = BorderStyleEnum.None; //colours.Style.BackgroundColor.Color = Color.SaddleBrown; x = x + sizes.Width.Value; y = 0; wd = 0.9; ht = ht + 0; RectangleType qtys = ReportUtil.AddRectangle("qtys" + sufx, subrect.ReportItems, x, y, wd, ht); qtys.Style.BorderStyle.Default = BorderStyleEnum.None; //qtys.Style.BackgroundColor.Color = Color.SaddleBrown; #endregion [Lines AREA] #region [Header ] x = slno.Left.Value + 0.01; y = 0.09; wd = slno.Width.Value - 0.03; ht = 0.16; TextboxType lbl_slno = ReportUtil.AddTextbox("lbl_slno" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_slno.Value = "S.No"; lbl_slno.Style.Font("Calibri", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_slno.Style.TextAlign = TextAlignRptEnum.Center; x = styles.Left.Value + 0.01; y = 0.09; wd = styles.Width.Value - 0.03; ht = 0.16; TextboxType lbl_styles = ReportUtil.AddTextbox("lbl_styles" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_styles.Value = "Styles"; lbl_styles.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_styles.Style.TextAlign = TextAlignRptEnum.Center; x = article.Left.Value + 0.01; y = 0.09; wd = article.Width.Value - 0.03; ht = 0.16; TextboxType lbl_article = ReportUtil.AddTextbox("lbl_article" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_article.Value = "Article"; lbl_article.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_article.Style.TextAlign = TextAlignRptEnum.Center; x = particulars.Left.Value + 0.11; y = y + 0; wd = particulars.Width.Value - 0.13; ht = 0.16; TextboxType lbl_particulars = ReportUtil.AddTextbox("lbl_particulars" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_particulars.Value = "Particulars"; lbl_particulars.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_particulars.Style.TextAlign = TextAlignRptEnum.Left; x = sizes.Left.Value + 0.01; y = 0.09; wd = sizes.Width.Value - 0.03; ht = 0.16; TextboxType lbl_sizes = ReportUtil.AddTextbox("lbl_sizes" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_sizes.Value = "Sizes"; lbl_sizes.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_sizes.Style.TextAlign = TextAlignRptEnum.Center; x = colours.Left.Value + 0.01; y = 0.09; wd = colours.Width.Value - 0.03; ht = 0.16; TextboxType lbl_colours = ReportUtil.AddTextbox("lbl_colours" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_colours.Value = "Colours"; lbl_colours.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_colours.Style.TextAlign = TextAlignRptEnum.Center; x = qtys.Left.Value + 0.01; y = 0.09; wd = qtys.Width.Value - 0.03; ht = 0.16; TextboxType lbl_qty = ReportUtil.AddTextbox("lbl_qty" + sufx, subrect.ReportItems, x, y, wd, ht); lbl_qty.Value = "Quantity"; lbl_qty.Style.Font("Calibri", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal); lbl_qty.Style.TextAlign = TextAlignRptEnum.Center; #endregion [Header] #region [ Detail-Line ] x = 0; y = 0.4; wd = subrect.Width.Value; ht = 0.03; ListType listDetlLine = ReportUtil.AddList("listDetlLine" + sufx, subrect.ReportItems, x, y, wd, ht); listDetlLine.DataSetName = "MyDataSource_Items"; listDetlLine.Grouping = new GroupingType("group_" + POUTWARDITEMS.SLNO + ""); listDetlLine.Grouping.GroupExpressions.Add("=Fields!" + POUTWARDITEMS.SLNO + ".Value"); x = 0; y = 0; wd = 0.55; ht = 0.25; RectangleType listdetails_rect = ReportUtil.AddRectangle("listdetails_rect" + sufx, listDetlLine.ReportItems, x, y, wd, ht); listdetails_rect.Style.BorderStyle.Default = BorderStyleEnum.None; x = slno.Left.Value + 0.01; y = 0; wd = slno.Width.Value - 0.03; ht = ht + 0; TextboxType txt_slno = ReportUtil.AddTextbox("txt_slno" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_slno.Value = "=Fields!" + POUTWARDITEMS.SLNO + ".Value"; txt_slno.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); txt_slno.Style.TextAlign = TextAlignRptEnum.Center; x = styles.Left.Value + 0.01; y = 0; wd = styles.Width.Value - 0.01; ht = ht + 0; TextboxType txt_styles = ReportUtil.AddTextbox("txt_styles" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_styles.Value = "=Fields!" + POUTWARDITEMS.STYLE_ID + ".Value"; txt_styles.Style.TextAlign = TextAlignRptEnum.Center; txt_styles.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); x = article.Left.Value + 0.01; y = 0; wd = sizes.Width.Value - 0.01; ht = ht + 0; TextboxType txt_article = ReportUtil.AddTextbox("txt_article" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_article.Value = "=Fields!" + POUTWARDITEMS.ARTICLE_ID + ".Value"; txt_article.Style.TextAlign = TextAlignRptEnum.Center; txt_article.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); x = particulars.Left.Value + 0.05; y = 0; wd = particulars.Width.Value - 0.05; ht = ht + 0; TextboxType txt_product_name = ReportUtil.AddTextbox("txt_product_name" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_product_name.Value = "=Fields!" + POUTWARDITEMS.PRODUCT_ID + ".Value"; txt_product_name.Style.TextAlign = TextAlignRptEnum.Left; txt_product_name.CanGrow = true; txt_product_name.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); x = sizes.Left.Value + 0.01; y = 0; wd = sizes.Width.Value - 0.01; ht = ht + 0; TextboxType txt_sizes = ReportUtil.AddTextbox("txt_sizes" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_sizes.Value = "=Fields!" + POUTWARDITEMS.SIZES_ID + ".Value"; txt_sizes.Style.TextAlign = TextAlignRptEnum.Center; txt_sizes.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); x = colours.Left.Value + 0.01; y = 0; wd = sizes.Width.Value - 0.01; ht = ht + 0; TextboxType txt_colours = ReportUtil.AddTextbox("txt_colours" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_colours.Value = "=Fields!" + POUTWARDITEMS.COLOURS_ID + ".Value"; txt_colours.Style.TextAlign = TextAlignRptEnum.Center; txt_colours.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); x = qtys.Left.Value + 0.02; y = 0; wd = qtys.Width.Value - 0.05; ht = ht + 0; TextboxType txt_qty = ReportUtil.AddTextbox("txt_qty" + sufx, listdetails_rect.ReportItems, x, y, wd, ht); txt_qty.Value = "=Fields!" + POUTWARDITEMS.QTY + ".Value"; txt_qty.Style.TextAlign = TextAlignRptEnum.Center; txt_qty.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal); #endregion [Detail-Line] } // fn build details