Example #1
0
        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");
        }
Example #2
0
        private static void BuildDetail(BodyType rectWarper)
        {
            double x = 0, y = 0, wd = 7.66, ht = 0.1;


            CXSubRectangles rct = new CXSubRectangles();

            rct.sufx = ""; /*Now unused. Used before in A4 (i.e 2xA5) print*/

            rct.subrect = ReportUtil.AddRectangle("manirect" + rct.sufx, rectWarper.ReportItems, x, y, wd, ht);
            rct.subrect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //rct.subrect.Style.BackgroundColor.Color = Color.MistyRose;

            RectangleType heading = ReportUtil.AddRectangle("heading" + rct.sufx, rct.subrect.ReportItems, x, y, wd, 0.3);

            heading.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //heading.Style.BackgroundColor.Color = Color.MistyRose;

            Sub_rectangle_position(rct);

            Sub_header(rct);

            Sub_Details(rct);
        }// fn build details
Example #3
0
        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
Example #4
0
        private static void BuildDetail(RectangleType rectWarper)
        {
            double x = 0, y = 0, wd = 0, ht = 0;


            #region [rect]

            x = 0.35; y = 0.20; wd = 7.65; ht = 01;
            RectangleType manirect = ReportUtil.AddRectangle("manirect", rectWarper.ReportItems, x, y, wd, ht);
            manirect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //manirect.Style.BackgroundColor.Color = Color.Red;

            x = 0; y = 0; wd = wd + 0; ht = 5.6;
            RectangleType rect_1   = ReportUtil.AddRectangle("rect_1", manirect.ReportItems, x, y, wd, ht);
            rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            //rect_1.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = 0; wd = wd + 0; ht = 0.01;
            RectangleType title_rect = ReportUtil.AddRectangle("title_rect", rect_1.ReportItems, x, y, wd, ht);
            title_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //title_rect.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = y + title_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType party_rect = ReportUtil.AddRectangle("party_rect", rect_1.ReportItems, x, y, wd, ht);
            party_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //party_rect.Style.BackgroundColor.Color = Color.Blue;

            x = 0; y = y + party_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType items_rect = ReportUtil.AddRectangle("items_rect", rect_1.ReportItems, x, y, wd, ht);
            items_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            items_rect.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //items_rect.Style.BackgroundColor.Color = Color.Green;

            x = 0; y = y + items_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType ledger_rect = ReportUtil.AddRectangle("ledger_rect", rect_1.ReportItems, x, y, wd, ht);
            ledger_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            ledger_rect.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //ledger_rect.Style.BackgroundColor.Color = Color.Red;

            x = 0; y = y + ledger_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType grandtotal_rect = ReportUtil.AddRectangle("grandtotal_rect", rect_1.ReportItems, x, y, wd, ht);
            grandtotal_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            grandtotal_rect.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //grandtotal_rect.Style.BackgroundColor.Color = Color.Aquamarine;

            x = 0; y = y + grandtotal_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType balance_rect = ReportUtil.AddRectangle("balance_rect", rect_1.ReportItems, x, y, wd, ht);
            balance_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            balance_rect.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //balance_rect.Style.BackgroundColor.Color = Color.Aquamarine;

            x = 0; y = y + balance_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType Sign_rect = ReportUtil.AddRectangle("Sign_rect", rect_1.ReportItems, x, y, wd, ht);
            Sign_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //Sign_rect.Style.BackgroundColor.Color = Color.Aquamarine;

            #endregion [rect]

            #region [Title]

            x = 0; y = 0.01; wd = title_rect.Width.Value; ht = 0.30;
            TextboxType txt_title = ReportUtil.AddTextbox("txt_title", title_rect.ReportItems, x, y, wd, ht);
            txt_title.Value           = "QUOTATION";
            txt_title.Style.TextAlign = TextAlignRptEnum.Center;
            txt_title.Style.Font(PrintConfig.TitleTxtFont, 16, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_title.Style.TextDecoration = TextDecorationEnum.Underline;

            #endregion [Title]

            #region [party]

            x = 0; y = 0; wd = 5; ht = 0.1;
            RectangleType party_area = ReportUtil.AddRectangle("party_area", party_rect.ReportItems, x, y, wd, ht);
            party_area.Style.BorderStyle.Default = BorderStyleEnum.None;
            //party_area.Style.BackgroundColor.Color = Color.Green;

            x = wd; y = 0; wd = party_rect.Width.Value - wd; ht = ht + 0;
            RectangleType nodt_rect = ReportUtil.AddRectangle("nodt_rect", party_rect.ReportItems, x, y, wd, ht);
            nodt_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //nodt_rect.Style.BackgroundColor.Color = Color.DarkOrange;


            x = 0.2; y = 0.08; wd = party_area.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType txt_partyname = ReportUtil.AddTextbox("txt_partyname", party_area.ReportItems, x, y, wd, ht);
            txt_partyname.Value   = "=Fields!" + PQuotation.PARTY_NAME + ".Value";
            txt_partyname.CanGrow = true;
            txt_partyname.Style.Font(PrintConfig.PartyTxtFont, 12, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_partyname.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_partyname.Style.BackgroundColor.Color = Color.SandyBrown;

            x = x + 0; y = y + 0.2; wd = wd + 0; ht = ht + 0;
            TextboxType txt_city = ReportUtil.AddTextbox("txt_city", party_area.ReportItems, x, y, wd, ht);
            txt_city.Value = "=Fields!" + PQuotation.CITY + ".Value";
            txt_city.Style.Font(PrintConfig.PartyTxtFont, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_city.Style.TextAlign = TextAlignRptEnum.Left;
            txt_city.CanGrow         = true;
            //txt_city.Style.BackgroundColor.Color = Color.SkyBlue;

            x = 0.20; y = txt_partyname.Top.Value; wd = nodt_rect.Width.Value - (x + 0.01); ht = 0.25;
            TextboxType txt_no = ReportUtil.AddTextbox("txt_no", nodt_rect.ReportItems, x, y, wd, ht);
            txt_no.Value = "=Fields!" + PQuotation.QUOTATION_NO + ".Value";
            txt_no.Style.Font(PrintConfig.PartyTxtFont, 12, FontWeightEnum.Normal, FontStyleEnum.Normal);

            x = x + 0; y = y + 0.25; wd = wd + 0; ht = 0.20;
            TextboxType txt_date = ReportUtil.AddTextbox("txt_date", nodt_rect.ReportItems, x, y, wd, ht);
            txt_date.Value        = "=Fields!" + PQuotation.QUOTATION_DATE + ".Value";
            txt_date.Style.Format = "dd-MM-yyyy";
            txt_date.Style.Font(PrintConfig.PartyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);

            #endregion [party]

            #region [sub]

            x = 0; y = 0; wd = items_rect.Width.Value; ht = 0.1;
            ReportUtil.AddSubreport("subreport_Print_quotationItems", "P_QuotationItem", items_rect.ReportItems, x, y, wd, ht);

            #endregion [sub]

            #region [Ledger]

            x = 4.8; y = 0.01; wd = 2; ht = 0.18;
            TextboxType txt_ledger = ReportUtil.AddTextbox("txt_ledger", ledger_rect.ReportItems, x, y, wd, ht);
            txt_ledger.Value = "=Fields!" + PQuotation.LEDGER + ".Value";
            txt_ledger.Style.Font(PrintConfig.BodyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_ledger.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_ledger.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 6.3; y = txt_ledger.Top.Value; wd = 1.33; ht = 0.18;
            TextboxType txt_additional = ReportUtil.AddTextbox("txt_additional", ledger_rect.ReportItems, x, y, wd, ht);
            txt_additional.Value = "=Fields!" + PQuotation.ADDITIONAL + ".Value";
            txt_additional.Style.Font(PrintConfig.BodyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_additional.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_additional.Style.BackgroundColor.Color = Color.Tan;

            #endregion [Ledger]

            #region [Grand total]

            x = 0; y = 0; wd = 5.05; ht = 0.1;
            RectangleType amtnwords = ReportUtil.AddRectangle("amtnwords", grandtotal_rect.ReportItems, x, y, wd, ht);
            amtnwords.Style.BorderStyle.Default = BorderStyleEnum.None;
            //amtnwords.Style.BackgroundColor.Color = Color.Red;

            x = 0.05; y = 0.01; wd = 4.7; ht = 0.19;
            TextboxType txt_amtnwords = ReportUtil.AddTextbox("txt_amtnwords", amtnwords.ReportItems, x, y, wd, ht);
            txt_amtnwords.Value   = "=Fields!" + PQuotation.AMOUNT_IN_WORDS + ".Value";
            txt_amtnwords.CanGrow = true;
            txt_amtnwords.Style.Font(PrintConfig.BodyTxtFont, 9, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_amtnwords.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_amtnwords.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 5; y = 0.01; wd = 1.3; ht = 0.19;
            TextboxType lbl_grandtotal = ReportUtil.AddTextbox("lbl_grandtotal", grandtotal_rect.ReportItems, x, y, wd, ht);
            lbl_grandtotal.Value = "  GRAND TOTAL";
            lbl_grandtotal.Style.Font(PrintConfig.BodyTxtFont, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_grandtotal.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_grandtotal.Style.BackgroundColor.Color = Color.DeepSkyBlue;
            //lbl_grandtotal.Style.BorderStyle.Left = BorderStyleEnum.Outset;

            x = 6.2; y = 0.01; wd = 1.43; ht = 0.19;
            TextboxType txt_grandtotal = ReportUtil.AddTextbox("txt_grandtotal", grandtotal_rect.ReportItems, x, y, wd, ht);
            txt_grandtotal.Value = "=Fields!" + PQuotation.GRANDTOTAL + ".Value";
            txt_grandtotal.Style.Font(PrintConfig.BodyTxtFont, 11, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_grandtotal.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_grandtotal.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [Grand total]

            #region [Outstanding]

            x = 0; y = 0.01; wd = balance_rect.Width.Value - 0.03; ht = 0.18;
            TextboxType txt_balance = ReportUtil.AddTextbox("txt_balance", balance_rect.ReportItems, x, y, wd, ht);
            txt_balance.Value = "=Fields!" + PQuotation.OUTSTANDING + ".Value";
            txt_balance.Style.Font(PrintConfig.BodyTxtFont, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_balance.Style.TextAlign = TextAlignRptEnum.Center;
            //txt_balance.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [Outstanding]

            #region [sign]

            x = 0; y = 0.08; wd = Sign_rect.Width.Value - 0.8; ht = 0.28;
            TextboxType txt_forsign = ReportUtil.AddTextbox("txt_forsign", Sign_rect.ReportItems, x, y, wd, ht);
            txt_forsign.Value = "Recevier Sign                                Prepared by                                               Party Sign";
            txt_forsign.Style.Font(PrintConfig.BodyTxtFont, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_forsign.Style.TextAlign = TextAlignRptEnum.Center;
            //txt_forsign.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [sign]

            //
            // copy 2
            //

            #region [rect]

            x = 0; y = rect_1.Height.Value + 0.10; wd = 7.65; ht = 5.6;
            RectangleType rect_2 = ReportUtil.AddRectangle("rect_2", manirect.ReportItems, x, y, wd, ht);
            rect_2.Style.BorderStyle.Default = BorderStyleEnum.None;
            //rect_2.Style.BackgroundColor.Color = Color.Green;

            x = 0; y = Sign_rect.Height.Value + 0.10; wd = wd + 0; ht = 0.01;
            RectangleType title_rect_1 = ReportUtil.AddRectangle("title_rect_1", rect_2.ReportItems, x, y, wd, ht);
            title_rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            //title_rect_1.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = y + title_rect_1.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType party_rect_1 = ReportUtil.AddRectangle("party_rect_1", rect_2.ReportItems, x, y, wd, ht);
            party_rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            //party_rect_1.Style.BackgroundColor.Color = Color.Blue;

            x = 0; y = y + party_rect_1.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType items_rect_1 = ReportUtil.AddRectangle("items_rect_1", rect_2.ReportItems, x, y, wd, ht);
            items_rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            items_rect_1.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //items_rect_1.Style.BackgroundColor.Color = Color.Green;

            x = 0; y = y + items_rect_1.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType ledger_rect_1 = ReportUtil.AddRectangle("ledger_rect_1", rect_2.ReportItems, x, y, wd, ht);
            ledger_rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            ledger_rect_1.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //ledger_rect_1.Style.BackgroundColor.Color = Color.Red;

            x = 0; y = y + ledger_rect_1.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType grandtotal_rect_1 = ReportUtil.AddRectangle("grandtotal_rect_1", rect_2.ReportItems, x, y, wd, ht);
            grandtotal_rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            grandtotal_rect_1.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //grandtotal_rect_1.Style.BackgroundColor.Color = Color.Aquamarine;

            x = 0; y = y + grandtotal_rect_1.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType balance_rect_1 = ReportUtil.AddRectangle("balance_rect_1", rect_2.ReportItems, x, y, wd, ht);
            balance_rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            balance_rect_1.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //balance_rect_1.Style.BackgroundColor.Color = Color.Aquamarine;

            x = 0; y = y + balance_rect_1.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType Sign_rect_1 = ReportUtil.AddRectangle("Sign_rect_1", rect_2.ReportItems, x, y, wd, ht);
            Sign_rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            //Sign_rect_1.Style.BackgroundColor.Color = Color.SaddleBrown;

            #endregion [rect]

            #region [Title]

            x = 0; y = 0.01; wd = title_rect_1.Width.Value; ht = 0.30;
            TextboxType txt_title_1 = ReportUtil.AddTextbox("txt_title_1", title_rect_1.ReportItems, x, y, wd, ht);
            txt_title_1.Value           = "QUOTATION";
            txt_title_1.Style.TextAlign = TextAlignRptEnum.Center;
            txt_title_1.Style.Font(PrintConfig.TitleTxtFont, 16, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_title_1.Style.TextDecoration = TextDecorationEnum.Underline;

            #endregion [Title]

            #region [party]

            x = 0; y = 0; wd = 5; ht = 0.1;
            RectangleType party_area_1 = ReportUtil.AddRectangle("party_area_1", party_rect_1.ReportItems, x, y, wd, ht);
            party_area_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            //party_area_1.Style.BackgroundColor.Color = Color.Green;

            x = wd; y = 0; wd = party_rect_1.Width.Value - wd; ht = ht + 0;
            RectangleType nodt_rect_1 = ReportUtil.AddRectangle("nodt_rect_1", party_rect_1.ReportItems, x, y, wd, ht);
            nodt_rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            //nodt_rect_1.Style.BackgroundColor.Color = Color.DarkOrange;


            x = 0.2; y = 0.08; wd = party_area_1.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType txt_partyname_1 = ReportUtil.AddTextbox("txt_partyname_1", party_area_1.ReportItems, x, y, wd, ht);
            txt_partyname_1.Value   = "=Fields!" + PQuotation.PARTY_NAME + ".Value";
            txt_partyname_1.CanGrow = true;
            txt_partyname_1.Style.Font(PrintConfig.PartyTxtFont, 12, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_partyname_1.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_partyname_1.Style.BackgroundColor.Color = Color.SandyBrown;

            x = x + 0; y = y + 0.2; wd = wd + 0; ht = ht + 0;
            TextboxType txt_city_1 = ReportUtil.AddTextbox("txt_city_1", party_area_1.ReportItems, x, y, wd, ht);
            txt_city_1.Value = "=Fields!" + PQuotation.CITY + ".Value";
            txt_city_1.Style.Font(PrintConfig.PartyTxtFont, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_city_1.Style.TextAlign = TextAlignRptEnum.Left;
            txt_city_1.CanGrow         = true;
            //txt_city_1.Style.BackgroundColor.Color = Color.SkyBlue;

            x = 0.20; y = txt_partyname_1.Top.Value; wd = nodt_rect_1.Width.Value - (x + 0.01); ht = 0.25;
            TextboxType txt_no_1 = ReportUtil.AddTextbox("txt_no_1", nodt_rect_1.ReportItems, x, y, wd, ht);
            txt_no_1.Value = "=Fields!" + PQuotation.QUOTATION_NO + ".Value";
            txt_no_1.Style.Font(PrintConfig.PartyTxtFont, 12, FontWeightEnum.Normal, FontStyleEnum.Normal);

            x = x + 0; y = y + 0.25; wd = wd + 0; ht = 0.20;
            TextboxType txt_date_1 = ReportUtil.AddTextbox("txt_date_1", nodt_rect_1.ReportItems, x, y, wd, ht);
            txt_date_1.Value        = "=Fields!" + PQuotation.QUOTATION_DATE + ".Value";
            txt_date_1.Style.Format = "dd-MM-yyyy";
            txt_date_1.Style.Font(PrintConfig.PartyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);

            #endregion [party]

            #region [sub]

            x = 0; y = 0; wd = items_rect_1.Width.Value; ht = 0.1;
            ReportUtil.AddSubreport("subreport_Print_quotationItems_1", "P_QuotationItem", items_rect_1.ReportItems, x, y, wd, ht);

            #endregion [sub]

            #region [Ledger]

            x = 4.8; y = 0.01; wd = 2; ht = 0.18;
            TextboxType txt_ledger_1 = ReportUtil.AddTextbox("txt_ledger_1", ledger_rect_1.ReportItems, x, y, wd, ht);
            txt_ledger_1.Value = "=Fields!" + PQuotation.LEDGER + ".Value";
            txt_ledger_1.Style.Font(PrintConfig.BodyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_ledger_1.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_ledger_1.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 6.3; y = txt_ledger_1.Top.Value; wd = 1.33; ht = 0.18;
            TextboxType txt_additional_1 = ReportUtil.AddTextbox("txt_additional_1", ledger_rect_1.ReportItems, x, y, wd, ht);
            txt_additional_1.Value = "=Fields!" + PQuotation.ADDITIONAL + ".Value";
            txt_additional_1.Style.Font(PrintConfig.BodyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_additional_1.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_additional_1.Style.BackgroundColor.Color = Color.Tan;

            #endregion [Ledger]

            #region [Grand total]

            x = 0; y = 0; wd = 5.05; ht = 0.1;
            RectangleType amtnwords_1 = ReportUtil.AddRectangle("amtnwords_1", grandtotal_rect_1.ReportItems, x, y, wd, ht);
            amtnwords_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            //amtnwords_1.Style.BackgroundColor.Color = Color.Red;

            x = 0.05; y = 0.01; wd = 4.7; ht = 0.19;
            TextboxType txt_amtnwords_1 = ReportUtil.AddTextbox("txt_amtnwords_1", amtnwords_1.ReportItems, x, y, wd, ht);
            txt_amtnwords_1.Value   = "=Fields!" + PQuotation.AMOUNT_IN_WORDS + ".Value";
            txt_amtnwords_1.CanGrow = true;
            txt_amtnwords_1.Style.Font(PrintConfig.BodyTxtFont, 9, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_amtnwords_1.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_amtnwords_1.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 5; y = 0.01; wd = 1.3; ht = 0.19;
            TextboxType lbl_grandtotal_1 = ReportUtil.AddTextbox("lbl_grandtotal_1", grandtotal_rect_1.ReportItems, x, y, wd, ht);
            lbl_grandtotal_1.Value = "  GRAND TOTAL";
            lbl_grandtotal_1.Style.Font(PrintConfig.BodyTxtFont, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_grandtotal_1.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_grandtotal_1.Style.BackgroundColor.Color = Color.DeepSkyBlue;
            //lbl_grandtotal_1.Style.BorderStyle.Left = BorderStyleEnum.Outset;

            x = 6.2; y = 0.01; wd = 1.43; ht = 0.19;
            TextboxType txt_grandtotal_1 = ReportUtil.AddTextbox("txt_grandtotal_1", grandtotal_rect_1.ReportItems, x, y, wd, ht);
            txt_grandtotal_1.Value = "=Fields!" + PQuotation.GRANDTOTAL + ".Value";
            txt_grandtotal_1.Style.Font(PrintConfig.BodyTxtFont, 11, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_grandtotal_1.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_grandtotal_1.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [Grand total]

            #region [Outstanding]

            x = 0; y = 0.01; wd = balance_rect_1.Width.Value - 0.03; ht = 0.18;
            TextboxType txt_balance_1 = ReportUtil.AddTextbox("txt_balance_1", balance_rect_1.ReportItems, x, y, wd, ht);
            txt_balance_1.Value = "=Fields!" + PQuotation.OUTSTANDING + ".Value";
            txt_balance_1.Style.Font(PrintConfig.BodyTxtFont, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_balance_1.Style.TextAlign = TextAlignRptEnum.Center;
            //txt_balance_1.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [Outstanding]

            #region [sign]

            x = 0; y = 0.08; wd = Sign_rect_1.Width.Value - 0.8; ht = 0.28;
            TextboxType txt_forsign_1 = ReportUtil.AddTextbox("txt_forsign_1", Sign_rect_1.ReportItems, x, y, wd, ht);
            txt_forsign_1.Value = "Recevier Sign                                Prepared by                                               Party Sign";
            txt_forsign_1.Style.Font(PrintConfig.BodyTxtFont, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_forsign_1.Style.TextAlign = TextAlignRptEnum.Center;
            //txt_forsign_1.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [sign]
        } // fn build details
Example #5
0
        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");
        }
Example #6
0
        private static void BuildDetail(RectangleType rectWarper)
        {
            double x = 0, y = 0, wd = 0, ht = 0;
            string sufx = "";

            x = 0.35; y = 0.32; wd = 7.65; ht = 01;
            RectangleType manirect = ReportUtil.AddRectangle("manirect" + sufx, rectWarper.ReportItems, x, y, wd, ht);

            manirect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //manirect.Style.BackgroundColor.Color = Color.Red;

            #region [rectangles]


            x = 0; y = 0; wd = wd + 0; ht = 0.01;
            RectangleType company_rect = ReportUtil.AddRectangle("company_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            company_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //company_rect.Style.BackgroundColor.Color = Color.Red;

            x = 0; y = ht + 0; wd = wd + 0; ht = 0.01;
            RectangleType Title_rect = ReportUtil.AddRectangle("Title_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            Title_rect.Style.BorderStyle.Default   = BorderStyleEnum.Outset;
            Title_rect.Style.BackgroundColor.Color = Color.Gray;

            x = 0; y = y + Title_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType No_rect = ReportUtil.AddRectangle("No_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            No_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //No_rect.Style.BackgroundColor.Color = Color.DarkBlue;

            x = 0; y = y + Title_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType consigneelbl_rect = ReportUtil.AddRectangle("consigneelbl_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            consigneelbl_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //consigneelbl_rect.Style.BackgroundColor.Color = Color.SaddleBrown;

            x = 0; y = y + consigneelbl_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType party_rect = ReportUtil.AddRectangle("party_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            party_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //party_rect.Style.BackgroundColor.Color = Color.SaddleBrown;

            x = 0; y = y + party_rect.Height.Value + 0.04; wd = wd + 0; ht = 4.8;
            RectangleType items_rect = ReportUtil.AddRectangle("items_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            items_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //items_rect.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = y + items_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType subtotal_rect = ReportUtil.AddRectangle("subtotal_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            subtotal_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //subtotal_rect.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = y + subtotal_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType total_rect = ReportUtil.AddRectangle("total_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            total_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //total_rect.Style.BackgroundColor.Color = Color.Crimson;

            x = 0; y = y + total_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType grandtotal_rect = ReportUtil.AddRectangle("grandtotal_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            grandtotal_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //grandtotal_rect.Style.BackgroundColor.Color = Color.Aquamarine;

            x = 0; y = y + grandtotal_rect.Height.Value; wd = wd = wd + 0; ht = 0.1;
            RectangleType sign_rect = ReportUtil.AddRectangle("sign_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            sign_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //sign_rect.Style.BackgroundColor.Color = Color.Black;

            x = 0; y = y + sign_rect.Height.Value; wd = wd = wd + 0; ht = 0.1;
            RectangleType juridiction_rect = ReportUtil.AddRectangle("juridiction_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            juridiction_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //juridiction_rect.Style.BackgroundColor.Color = Color.Cyan;

            #endregion [rectangles]

            #region [ Title ]

            x = 0; y = 0.01; wd = Title_rect.Width.Value; ht = 0.23;
            TextboxType txt_title = ReportUtil.AddTextbox("txtTitle" + sufx, Title_rect.ReportItems, x, y, wd, ht);
            txt_title.Value             = "TAX INVOICE";
            txt_title.Style.TextAlign   = TextAlignRptEnum.Center;
            txt_title.Style.Color.Color = Color.White;
            txt_title.Style.Font("Arial", 16, FontWeightEnum.Bolder, FontStyleEnum.Normal);

            x = 0; y = 0.04; wd = Title_rect.Width.Value; ht = ht + 0;
            TextboxType txt_copy = ReportUtil.AddTextbox("txtCopy" + sufx, Title_rect.ReportItems, x, y, wd, ht);
            txt_copy.Value           = "=Fields!" + PInvoice.COPIES + ".Value";
            txt_copy.Style.TextAlign = TextAlignRptEnum.Right;
            txt_copy.Style.Font("Arial", 12, FontWeightEnum.Bolder, FontStyleEnum.Italic);
            txt_copy.Style.Color.Color = Color.White;

            #endregion [ Title ]

            #region [ COMPANY AREA]

            x = 0; y = 0; wd = 0.9; ht = 0.95;
            RectangleType Company_logo = ReportUtil.AddRectangle("Company_logo" + sufx, company_rect.ReportItems, x, y, wd, ht);
            Company_logo.Style.BorderStyle.Default = BorderStyleEnum.None;
            //Company_logo.Style.BackgroundColor.Color = Color.DarkBlue;

            x = wd; y = 0; wd = company_rect.Width.Value - (x + 0.01); ht = ht + 0;
            RectangleType Company_txt = ReportUtil.AddRectangle("Company_txt" + sufx, company_rect.ReportItems, x, y, wd, ht);
            Company_txt.Style.BorderStyle.Default = BorderStyleEnum.None;
            //Company_txt.Style.BackgroundColor.Color = Color.SaddleBrown;

            #region [ Company txt]

            x = 0; y = 0.05; wd = Company_txt.Width.Value - 0.02; ht = 0.4;
            TextboxType txt_compname = ReportUtil.AddTextbox("txt_compname" + sufx, Company_txt.ReportItems, x, y, wd, ht);
            txt_compname.Value = "=Fields!" + PInvoice.COMPANY_NAME + ".Value";
            txt_compname.Style.Font("Calibri", 30, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_compname.Style.TextAlign = TextAlignRptEnum.Center;
            //txt_compname.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.50; wd = wd + 0; ht = 0.18;
            TextboxType txt_address1 = ReportUtil.AddTextbox("txt_address1" + sufx, Company_txt.ReportItems, x, y, wd, ht);
            txt_address1.Value = "=Fields!" + PInvoice.ADDRESS1 + ".Value";
            txt_address1.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_address1.Style.TextAlign = TextAlignRptEnum.Center;
            //txt_address1.Style.BackgroundColor.Color = Color.AntiqueWhite;

            x = 0; y = y + 0.17; wd = wd + 0; ht = 0.18;
            TextboxType txt_address2 = ReportUtil.AddTextbox("txt_address2" + sufx, Company_txt.ReportItems, x, y, wd, ht);
            txt_address2.Value = "=Fields!" + PInvoice.ADDRESS2 + ".Value";
            txt_address2.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_address2.Style.TextAlign = TextAlignRptEnum.Center;
            //t_address2.Style.BackgroundColor.Color = Color.SeaGreen;

            x = 0.03; y = y + 0.17; wd = wd - x; ht = 0.18;
            TextboxType txt_company_tin = ReportUtil.AddTextbox("txt_company_tin" + sufx, Company_txt.ReportItems, x, y, wd, ht);
            txt_company_tin.Value = "=Fields!" + PInvoice.COMPANY_TIN + ".Value";
            txt_company_tin.Style.Font("Tahoma", 8, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_company_tin.Style.TextAlign = TextAlignRptEnum.Center;
            //txt_company_tin.Style.BackgroundColor.Color = Color.RoyalBlue;

            #endregion [ Company txt]

            #endregion [ COMPANY AREA]

            #region [No AREA]

            x = 0; y = 0; wd = 4; ht = 0.1;
            RectangleType no_area = ReportUtil.AddRectangle("no_area" + sufx, No_rect.ReportItems, x, y, wd, ht);
            no_area.Style.BorderStyle.Default = BorderStyleEnum.None;
            no_area.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //no_area.Style.BackgroundColor.Color = Color.Green;

            x = wd; y = 0; wd = No_rect.Width.Value - wd; ht = ht + 0;
            RectangleType transport_rect = ReportUtil.AddRectangle("transport_rect" + sufx, No_rect.ReportItems, x, y, wd, ht);
            transport_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //transport_rect.Style.BackgroundColor.Color = Color.DarkOrange;

            #region [gst - No -sales type - date]

            x = 0.18; y = 0.04; wd = no_area.Width.Value - (x + 0.2); ht = 0.16;
            TextboxType lbl_gstinno = ReportUtil.AddTextbox("lbl_gstinno" + sufx, no_area.ReportItems, x, y, wd, ht);
            lbl_gstinno.Value = "=Fields!" + PInvoice.COMPANY_GST + ".Value";
            lbl_gstinno.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_gstinno.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_gstinno.Style.BackgroundColor.Color = Color.Salmon;

            x = x + 0; y = y + ht; wd = no_area.Width.Value - (x + 0.2); ht = 0.16;
            TextboxType lbl_salestype = ReportUtil.AddTextbox("lbl_salestype" + sufx, no_area.ReportItems, x, y, wd, ht);
            lbl_salestype.Value = "=Fields!" + PInvoice.SALES_TYPE + ".Value";
            lbl_salestype.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_salestype.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_salestype.Style.BackgroundColor.Color = Color.Salmon;

            x = x + 0; y = y + ht; wd = no_area.Width.Value - (x + 0.2); ht = 0.16;
            TextboxType lbl_no = ReportUtil.AddTextbox("lbl_no" + sufx, no_area.ReportItems, x, y, wd, ht);
            lbl_no.Value = "=Fields!" + PInvoice.INVOICE_NO + ".Value";
            lbl_no.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_no.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_no.Style.BackgroundColor.Color = Color.Salmon;

            x = x + 0; y = y + ht; wd = no_area.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType lbl_date = ReportUtil.AddTextbox("lbl_date" + sufx, no_area.ReportItems, x, y, wd, ht);
            lbl_date.Value = "=Fields!" + PInvoice.INVOICE_DATE + ".Value";
            lbl_date.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_date.Style.TextAlign = TextAlignRptEnum.Left;
            lbl_date.Style.Format    = "dd-MM-yyyy";
            //lbl_date.Style.BackgroundColor.Color = Color.Salmon;

            #endregion [gst - No -sales type - date]

            #region [ No - Dt ]

            x = 0.18; y = 0.20; wd = transport_rect.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType lbl_modeoftransport = ReportUtil.AddTextbox("lbl_modeoftransport" + sufx, transport_rect.ReportItems, x, y, wd, ht);
            lbl_modeoftransport.Value = "=Fields!" + PInvoice.TRANSPORT + ".Value";
            lbl_modeoftransport.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_modeoftransport.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_modeoftransport.Style.BackgroundColor.Color = Color.Salmon;

            //x = x + 0; y = y + ht; wd = transport_rect.Width.Value - (x + 0.2); ht = 0.20;
            //TextboxType lbl_vehicle = ReportUtil.AddTextbox("lbl_vehicle" + sufx, transport_rect.ReportItems, x, y, wd, ht);
            //lbl_vehicle.Value = "=Fields!" + PInvoice.VEHICLE_NO + ".Value";
            //lbl_vehicle.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            //lbl_vehicle.Style.TextAlign = TextAlignRptEnum.Left;
            ////lbl_vehicle.Style.BackgroundColor.Color = Color.Salmon;

            x = x + 0; y = y + ht; wd = transport_rect.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType lbl_place = ReportUtil.AddTextbox("lbl_place" + sufx, transport_rect.ReportItems, x, y, wd, ht);
            lbl_place.Value = "=Fields!" + PInvoice.PLACE + ".Value";
            lbl_place.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_place.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_place.Style.BackgroundColor.Color = Color.Salmon;

            #endregion [ No - Dt ]

            #endregion [Party area]

            #region [billto]

            x = 0; y = 0; wd = 4; ht = 0.1;
            RectangleType billto = ReportUtil.AddRectangle("billto" + sufx, consigneelbl_rect.ReportItems, x, y, wd, ht);
            billto.Style.BorderStyle.Default = BorderStyleEnum.None;
            billto.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //billto.Style.BackgroundColor.Color = Color.Green;

            x = 0.02; y = 0.02; wd = billto.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType header_party = ReportUtil.AddTextbox("header_party" + sufx, billto.ReportItems, x, y, wd, ht);
            header_party.Value = "Details of Receiver (Billed to)";
            header_party.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            header_party.Style.TextAlign = TextAlignRptEnum.Center;
            //header_party.Style.BackgroundColor.Color = Color.Salmon;

            x = wd; y = 0; wd = consigneelbl_rect.Width.Value - wd; ht = ht + 0;
            RectangleType shippingto = ReportUtil.AddRectangle("shippingto" + sufx, consigneelbl_rect.ReportItems, x, y, wd, ht);
            shippingto.Style.BorderStyle.Default = BorderStyleEnum.None;
            //shippingto.Style.BackgroundColor.Color = Color.DarkOrange;

            x = 0.02; y = 0.02; wd = shippingto.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType header_shipping = ReportUtil.AddTextbox("header_shipping" + sufx, shippingto.ReportItems, x, y, wd, ht);
            header_shipping.Value = "Details of Consignee (Shipped to)";
            header_shipping.Style.Font("Calibri", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            header_shipping.Style.TextAlign = TextAlignRptEnum.Center;
            //header_shipping.Style.BackgroundColor.Color = Color.Salmon;

            #endregion [ Party - Address]

            #region [ Party AREA]

            x = 0; y = 0; wd = 4; ht = 1.1;
            RectangleType party_area = ReportUtil.AddRectangle("party_area" + sufx, party_rect.ReportItems, x, y, wd, ht);
            party_area.Style.BorderStyle.Default = BorderStyleEnum.None;
            party_area.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //party_area.Style.BackgroundColor.Color = Color.Green;

            x = wd; y = 0; wd = party_rect.Width.Value - wd; ht = ht + 0;
            RectangleType shipping_rect = ReportUtil.AddRectangle("shipping_rect" + sufx, party_rect.ReportItems, x, y, wd, ht);
            shipping_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //nodt_rect.Style.BackgroundColor.Color = Color.DarkOrange;

            #endregion [ Party - Address]

            #region [ Party - Address]

            x = 0.08; y = 0.06; wd = party_area.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType txt_partyname = ReportUtil.AddTextbox("txt_partyname" + sufx, party_area.ReportItems, x, y, wd, ht);
            txt_partyname.Value   = "=Fields!" + PInvoice.PARTY_NAME + ".Value";
            txt_partyname.CanGrow = true;
            txt_partyname.Style.Font("Calibri", 12, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_partyname.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_partyname.Style.BackgroundColor.Color = Color.SandyBrown;

            x = x + 0; y = y + 0.20; wd = party_area.Width.Value - (x + 0.2); ht = ht + 0;
            TextboxType txt_street1 = ReportUtil.AddTextbox("txtStreet1" + sufx, party_area.ReportItems, x, y, wd, ht);
            txt_street1.CanGrow = true;
            txt_street1.Value   = "=Fields!" + PInvoice.STREET1 + ".Value";
            txt_street1.Style.Font("Calibri", 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_street1.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_street1.Style.BackgroundColor.Color = Color.SeaGreen;

            x = x + 0; y = y + 0.2; wd = wd + 0; ht = ht + 0;
            TextboxType txt_city = ReportUtil.AddTextbox("txt_city" + sufx, party_area.ReportItems, x, y, wd, ht);
            txt_city.Value = "=Fields!" + PInvoice.CITY + ".Value";
            txt_city.Style.Font("Calibri", 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_city.Style.TextAlign = TextAlignRptEnum.Left;
            txt_city.CanGrow         = true;
            //txt_city.Style.BackgroundColor.Color = Color.SkyBlue;

            x = x + 0; y = y + 0.18; wd = wd + 0; ht = ht + 0;
            TextboxType txt_tin = ReportUtil.AddTextbox("txt_tin" + sufx, party_area.ReportItems, x, y, wd, ht);
            txt_tin.Value = "=Fields!" + PInvoice.GSTIN + ".Value";
            txt_tin.Style.Font("Calibri", 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_tin.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_tin.Style.BackgroundColor.Color = Color.Sienna;

            #endregion [ Party - Address ]

            #region [ shipping_rect]

            x = 0.08; y = 0.08; wd = shipping_rect.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType shipping_partyname = ReportUtil.AddTextbox("shipping_partyname" + sufx, shipping_rect.ReportItems, x, y, wd, ht);
            shipping_partyname.Value   = "=Fields!" + PInvoice.SHIPPING_NAME + ".Value";
            shipping_partyname.CanGrow = true;
            shipping_partyname.Style.Font("Calibri", 12, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            shipping_partyname.Style.TextAlign = TextAlignRptEnum.Left;
            //shipping_partyname.Style.BackgroundColor.Color = Color.SandyBrown;

            x = x + 0; y = y + 0.20; wd = shipping_rect.Width.Value - (x + 0.2); ht = ht + 0;
            TextboxType shipping_street1 = ReportUtil.AddTextbox("shipping_street1" + sufx, shipping_rect.ReportItems, x, y, wd, ht);
            shipping_street1.CanGrow = true;
            shipping_street1.Value   = "=Fields!" + PInvoice.SHIPPING_STREET1 + ".Value";
            shipping_street1.Style.Font("Calibri", 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            shipping_street1.Style.TextAlign = TextAlignRptEnum.Left;
            //shipping_street1.Style.BackgroundColor.Color = Color.SeaGreen;

            x = x + 0; y = y + 0.2; wd = wd + 0; ht = ht + 0;
            TextboxType shipping_city = ReportUtil.AddTextbox("shipping__city" + sufx, shipping_rect.ReportItems, x, y, wd, ht);
            shipping_city.Value = "=Fields!" + PInvoice.SHIPPING_CITY + ".Value";
            shipping_city.Style.Font("Calibri", 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            shipping_city.Style.TextAlign = TextAlignRptEnum.Left;
            shipping_city.CanGrow         = true;
            //shipping_city.Style.BackgroundColor.Color = Color.SkyBlue;

            x = x + 0; y = y + 0.18; wd = wd + 0; ht = ht + 0;
            TextboxType shipping_tin = ReportUtil.AddTextbox("shipping_tin" + sufx, shipping_rect.ReportItems, x, y, wd, ht);
            shipping_tin.Value = "=Fields!" + PInvoice.SHIPPING_GSTIN + ".Value";
            shipping_tin.Style.Font("Calibri", 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            shipping_tin.Style.TextAlign = TextAlignRptEnum.Left;
            //shipping_tin.Style.BackgroundColor.Color = Color.Sienna;

            #endregion [ shipping_rect]

            #region [ ITEMS DETAILS AREA]

            x = 0; y = 0; wd = items_rect.Width.Value; ht = 0.1;
            ReportUtil.AddSubreport("subreport_Print_invoiceItems", "P_InvoiceItem", items_rect.ReportItems, x, y, wd, ht);

            #endregion [ ITEMS DETAILS AREA]

            #region [SUB TOTAL AREA]

            x = 0.03; y = 0.05; wd = 1.5; ht = 0.16;
            TextboxType lbl_eoe = ReportUtil.AddTextbox("lbl_eoe" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            lbl_eoe.Value = "E&OE";
            lbl_eoe.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            lbl_eoe.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_eoe.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.3; y = 0.03; wd = 1.35; ht = 0.16;
            TextboxType lbl_total = ReportUtil.AddTextbox("lbl_total" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            lbl_total.Value = "Total";
            lbl_total.Style.Font("Tahoma", 9, FontWeightEnum.Normal, FontStyleEnum.Normal);
            lbl_total.Style.TextAlign = TextAlignRptEnum.Right;

            x = 3.05; y = 0; wd = 0.4; ht = 0.2;
            RectangleType total_qty = ReportUtil.AddRectangle("total_qty" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_qty.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_qty.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_qty.Style.BorderStyle.Right   = BorderStyleEnum.Outset;

            x = 0; y = 0.03; wd = 0.4; ht = 0.16;
            TextboxType txt_qtys = ReportUtil.AddTextbox("txt_qtys" + sufx, total_qty.ReportItems, x, y, wd, ht);
            txt_qtys.Value = "=Fields!" + PInvoice.TOTAL_QTY + ".Value";
            txt_qtys.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_qtys.Style.TextAlign = TextAlignRptEnum.Center;

            x = 4.25; y = 0; wd = 0.5; ht = 0.2;
            RectangleType total_areasq = ReportUtil.AddRectangle("total_areasq" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_areasq.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_areasq.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_areasq.Style.BorderStyle.Right   = BorderStyleEnum.Outset;

            x = 0; y = 0.03; wd = 0.5; ht = 0.16;
            TextboxType txt_areasq = ReportUtil.AddTextbox("txt_areasq" + sufx, total_areasq.ReportItems, x, y, wd, ht);
            txt_areasq.Value = "=Fields!" + PInvoice.TOTAL_AREASQ + ".Value";
            txt_areasq.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_areasq.Style.TextAlign = TextAlignRptEnum.Center;

            x = 5.25; y = 0; wd = 0.7; ht = 0.2;
            RectangleType total_amt = ReportUtil.AddRectangle("total_amt" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_amt.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_amt.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_amt.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //total_amt.Style.BackgroundColor.Color = Color.OrangeRed;

            x = 0; y = 0.03; wd = 0.68; ht = 0.16;
            TextboxType txt_total = ReportUtil.AddTextbox("txt_total" + sufx, total_amt.ReportItems, x, y, wd, ht);
            txt_total.Value = "=Fields!" + PInvoice.TAXABLE_VALUE + ".Value";
            txt_total.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_total.Style.TextAlign = TextAlignRptEnum.Right;

            x = 6.15; y = 0; wd = 0.65; ht = 0.2;
            RectangleType total_sgst_rect = ReportUtil.AddRectangle("total_sgst_rect" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_sgst_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_sgst_rect.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_sgst_rect.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //total_sgst_rect.Style.BackgroundColor.Color = Color.BlueViolet;

            x = 0; y = 0.03; wd = 0.62; ht = 0.16;
            TextboxType total_sgst = ReportUtil.AddTextbox("total_sgst" + sufx, total_sgst_rect.ReportItems, x, y, wd, ht);
            total_sgst.Value = "=Fields!" + PInvoice.TOTAL_SGST + ".Value";
            total_sgst.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            total_sgst.Style.TextAlign = TextAlignRptEnum.Right;

            x = 7.0; y = 0; wd = 0.65; ht = 0.2;
            RectangleType total_cgst_rec = ReportUtil.AddRectangle("total_cgst_rec" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_cgst_rec.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_cgst_rec.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_cgst_rec.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //total_cgst_rec.Style.BackgroundColor.Color = Color.OrangeRed;

            x = 0; y = 0.03; wd = 0.62; ht = 0.16;
            TextboxType total_cgst = ReportUtil.AddTextbox("total_cgst" + sufx, total_cgst_rec.ReportItems, x, y, wd, ht);
            total_cgst.Value = "=Fields!" + PInvoice.TOTAL_CGST + ".Value";
            total_cgst.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            total_cgst.Style.TextAlign = TextAlignRptEnum.Right;

            x = 6.92; y = 0; wd = 0.71; ht = 0.2;
            RectangleType total_sub_rec = ReportUtil.AddRectangle("total_sub_rec" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_sub_rec.Style.BorderStyle.Default = BorderStyleEnum.None;
            //total_sub_rec.Style.BackgroundColor.Color = Color.OrangeRed;

            //x = 0; y = 0.03; wd = 0.69; ht = 0.16;
            //TextboxType total_sub = ReportUtil.AddTextbox("total_sub" + sufx, total_sub_rec.ReportItems, x, y, wd, ht);
            //total_sub.Value = "=Fields!" + PInvoice.TOTAL_SUB + ".Value";
            //total_sub.Style.Font("Tahoma", 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            //total_sub.Style.TextAlign = TextAlignRptEnum.Right;

            //x = 4.63; y = 0; wd = items_rect.Width.Value - x; ht = 0.2;
            //RectangleType total_line = ReportUtil.AddRectangle("total_line" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            //total_line.Style.BorderStyle.Default = BorderStyleEnum.None;
            //total_line.Style.BorderStyle.Bottom = BorderStyleEnum.Double;
            //total_line.Style.BorderStyle.Left = BorderStyleEnum.Double;
            //total_line.Style.BorderStyle.Right = BorderStyleEnum.None;

            #endregion [SUB TOTAL AREA]

            //#region [TOTAL AREA]

            #region [notes]

            x = 0; y = 0; wd = 4.4; ht = 0.6;
            RectangleType rect_notes = ReportUtil.AddRectangle("rect_notes" + sufx, total_rect.ReportItems, x, y, wd, ht);
            rect_notes.Style.BorderStyle.Default = BorderStyleEnum.None;
            //rect_notes.Style.BackgroundColor.Color = Color.OrangeRed;

            x = 0.05; y = 0.06; wd = 4.4; ht = 0.26;
            TextboxType txt_notes = ReportUtil.AddTextbox("txt_notes" + sufx, rect_notes.ReportItems, x, y, wd, ht);
            txt_notes.Value   = "=Fields!" + PInvoice.NOTES + ".Value";
            txt_notes.CanGrow = true;
            txt_notes.Style.Font("Tahoma", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_notes.Style.TextAlign = TextAlignRptEnum.Left;

            #endregion [notes]

            #region [Labels]

            x = 4.75; y = 0; wd = 2.85; ht = 0.1;
            RectangleType rect_totallbl = ReportUtil.AddRectangle("rect_totallbl" + sufx, total_rect.ReportItems, x, y, wd, ht);
            rect_totallbl.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //rect_totallbl.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0; wd = 2.85; ht = 0.01;
            RectangleType bx_1 = ReportUtil.AddRectangle("bx_1" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_1.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_1.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_taxablevalue = ReportUtil.AddTextbox("lbl_taxablevalue" + sufx, bx_1.ReportItems, x, y, wd, ht);
            lbl_taxablevalue.Value = "  Taxable Value";
            lbl_taxablevalue.Style.Font("Tahoma", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_taxablevalue.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_taxablevalue.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_taxablevalue.Top.Value; wd = 0.96; ht = 0.12;
            TextboxType txt_taxable_amt = ReportUtil.AddTextbox("txt_taxable_amt" + sufx, bx_1.ReportItems, x, y, wd, ht);
            txt_taxable_amt.Value = "=Fields!" + PInvoice.TAXABLE_VALUE + ".Value";
            txt_taxable_amt.Style.Font("Tahoma", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_taxable_amt.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_taxable_amt.Style.BackgroundColor.Color = Color.White;


            x = 0; y = 0.01; wd = 2.85; ht = 0.01;
            RectangleType bx_2 = ReportUtil.AddRectangle("bx_2" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_2.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_2.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_Sgst = ReportUtil.AddTextbox("lbl_Sgst" + sufx, bx_2.ReportItems, x, y, wd, ht);
            lbl_Sgst.Value = "=Fields!" + PInvoice.LBL_SGST + ".Value";
            lbl_Sgst.Style.Font("Tahoma", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_Sgst.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_Sgst.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_Sgst.Top.Value; wd = 0.96; ht = 0.12;
            TextboxType txt_Sgst = ReportUtil.AddTextbox("txt_Sgst" + sufx, bx_2.ReportItems, x, y, wd, ht);
            txt_Sgst.Value = "=Fields!" + PInvoice.TOTAL_SGST + ".Value";
            txt_Sgst.Style.Font("Tahoma", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_Sgst.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_Sgst.Style.BackgroundColor.Color = Color.White;


            x = 0; y = 0.02; wd = 2.85; ht = 0.01;
            RectangleType bx_3 = ReportUtil.AddRectangle("bx_3" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_3.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_3.Style.BackgroundColor.Color = Color.MistyRose;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_cgst = ReportUtil.AddTextbox("lbl_cgst" + sufx, bx_3.ReportItems, x, y, wd, ht);
            lbl_cgst.Value = "=Fields!" + PInvoice.LBL_CGST + ".Value";
            lbl_cgst.Style.Font("Tahoma", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_cgst.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_cgst.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_cgst.Top.Value; wd = 0.96; ht = 0.12;
            TextboxType txt_cgst = ReportUtil.AddTextbox("txt_cgst" + sufx, bx_3.ReportItems, x, y, wd, ht);
            txt_cgst.Value = "=Fields!" + PInvoice.TOTAL_CGST + ".Value";
            txt_cgst.Style.Font("Tahoma", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_cgst.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_cgst.Style.BackgroundColor.Color = Color.White;

            x = 0; y = 0.03; wd = 2.85; ht = 0.01;
            RectangleType bx_4 = ReportUtil.AddRectangle("bx_4" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_1.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_1.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_GSTTotal = ReportUtil.AddTextbox("lbl_GSTTotal" + sufx, bx_4.ReportItems, x, y, wd, ht);
            lbl_GSTTotal.Value = "  TOTAL GST TAX ";
            lbl_GSTTotal.Style.Font("Tahoma", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_GSTTotal.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_GSTTotal.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_GSTTotal.Top.Value; wd = 0.96; ht = 0.12;
            TextboxType txt_GSTTotal = ReportUtil.AddTextbox("txt_GSTTotal" + sufx, bx_4.ReportItems, x, y, wd, ht);
            txt_GSTTotal.Value = "=Fields!" + PInvoice.GSTTOTAL + ".Value";
            txt_GSTTotal.Style.Font("Tahoma", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_GSTTotal.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_GSTTotal.Style.BackgroundColor.Color = Color.White;


            x = 0; y = 0.04; wd = 2.85; ht = 0.01;
            RectangleType bx_5 = ReportUtil.AddRectangle("bx_5" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_1.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_1.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType txt_ledger = ReportUtil.AddTextbox("txt_ledger" + sufx, bx_5.ReportItems, x, y, wd, ht);
            txt_ledger.Value = "=Fields!" + PInvoice.LEDGER + ".Value";
            txt_ledger.Style.Font("Tahoma", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_ledger.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_ledger.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = txt_ledger.Top.Value; wd = 0.96; ht = 0.12;
            TextboxType txt_additional = ReportUtil.AddTextbox("txt_additional" + sufx, bx_5.ReportItems, x, y, wd, ht);
            txt_additional.Value = "=Fields!" + PInvoice.ADDITIONAL + ".Value";
            txt_additional.Style.Font("Tahoma", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_additional.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_additional.Style.BackgroundColor.Color = Color.White;


            x = 0; y = 0.05; wd = 2.85; ht = 0.01;
            RectangleType bx_6 = ReportUtil.AddRectangle("bx_6" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_1.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_1.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_round = ReportUtil.AddTextbox("lbl_round" + sufx, bx_6.ReportItems, x, y, wd, ht);
            lbl_round.Value = "  Round off ";
            lbl_round.Style.Font("Tahoma", 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_round.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_round.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_round.Top.Value; wd = 0.96; ht = 0.12;
            TextboxType txt_round = ReportUtil.AddTextbox("txt_round" + sufx, bx_6.ReportItems, x, y, wd, ht);
            txt_round.Value = "=Fields!" + PInvoice.ROUNDS + ".Value";
            txt_round.Style.Font("Tahoma", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_round.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_round.Style.BackgroundColor.Color = Color.Green;

            #endregion [total field]

            #region [Grand total]

            x = 0; y = 0; wd = 4.8; ht = 0.45;
            RectangleType amtnwords = ReportUtil.AddRectangle("amtnwords" + sufx, grandtotal_rect.ReportItems, x, y, wd, ht);
            amtnwords.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //amtnwords.Style.BackgroundColor.Color = Color.Red;

            x = 0.05; y = 0.01; wd = 4.7; ht = 0.4;
            TextboxType txt_amtnwords = ReportUtil.AddTextbox("txt_amtnwords" + sufx, amtnwords.ReportItems, x, y, wd, ht);
            txt_amtnwords.Value   = "=Fields!" + PInvoice.AMOUNT_IN_WORDS + ".Value";
            txt_amtnwords.CanGrow = true;
            txt_amtnwords.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_amtnwords.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_amtnwords.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 4.83; y = 0.08; wd = 1.3; ht = 0.28;
            TextboxType lbl_grandtotal = ReportUtil.AddTextbox("lbl_grandtotal" + sufx, grandtotal_rect.ReportItems, x, y, wd, ht);
            lbl_grandtotal.Value = "  GRAND TOTAL";
            lbl_grandtotal.Style.Font("Tahoma", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_grandtotal.Style.TextAlign = TextAlignRptEnum.Left;
            // lbl_grandtotal.Style.BackgroundColor.Color = Color.DeepSkyBlue;
            //lbl_grandtotal.Style.BorderStyle.Left = BorderStyleEnum.Outset;

            x = 6.20; y = 0.08; wd = 1.43; ht = 0.28;
            TextboxType txt_grandtotal = ReportUtil.AddTextbox("txt_grandtotal" + sufx, grandtotal_rect.ReportItems, x, y, wd, ht);
            txt_grandtotal.Value = "=Fields!" + PInvoice.GRANDTOTAL + ".Value";
            txt_grandtotal.Style.Font("Tahoma", 12, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_grandtotal.Style.TextAlign = TextAlignRptEnum.Right;
            // txt_grandtotal.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [Grand total]

            //#endregion [TOTAL AREA]

            #region [for SIGN AREA]

            #region [amounts in words]
            x = 0; y = 0; wd = 4.5; ht = 0.5;
            RectangleType receiver_rect = ReportUtil.AddRectangle("receiver_rect" + sufx, sign_rect.ReportItems, x, y, wd, ht);
            receiver_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //amtnwords.Style.BackgroundColor.Color = Color.Red;

            x = 0.05; y = 0.08; wd = wd - 0.2; ht = 0.18;
            TextboxType txt_receiversign = ReportUtil.AddTextbox("txt_receiversign" + sufx, receiver_rect.ReportItems, x, y, wd, ht);
            txt_receiversign.Value = "Receiver Signature";
            //txt_receiversign.CanGrow = true;
            txt_receiversign.Style.Font("Tahoma", 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_receiversign.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_receiversign.Style.BackgroundColor.Color = Color.Violet;

            #endregion [amounts in words]

            #region [Signature]

            x = amtnwords.Width.Value; y = 0; wd = 2.85; ht = 0.95;
            RectangleType forspace = ReportUtil.AddRectangle("forspace" + sufx, sign_rect.ReportItems, x, y, wd, ht);
            forspace.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //forspace.Style.BackgroundColor.Color = Color.Violet;

            x = 0.3; y = 0.06; wd = 1; ht = 0.16;
            TextboxType lbl_for = ReportUtil.AddTextbox("lbl_for" + sufx, forspace.ReportItems, x, y, wd, ht);
            lbl_for.Value = "For";
            lbl_for.Style.Font("Times New Roman", 9, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_for.Style.TextAlign = TextAlignRptEnum.Left;

            x = x + 0.3; y = 0.04; wd = 2.8 - x; ht = 0.20;
            TextboxType lbl_forcompany = ReportUtil.AddTextbox("lbl_forcompany" + sufx, forspace.ReportItems, x, y, wd, ht);
            lbl_forcompany.Value = "=Fields!" + PInvoice.COMPANY_NAME + ".Value";
            lbl_forcompany.Style.Font("Times New Roman", 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_forcompany.Style.TextAlign = TextAlignRptEnum.Left;

            x = lbl_for.Left.Value + 0.3; y = 0.70; wd = 2.4 - x; ht = 0.15;
            TextboxType lbl_sign = ReportUtil.AddTextbox("lbl_sign" + sufx, forspace.ReportItems, x, y, wd, ht);
            lbl_sign.Value = "    Authorized signatory";
            lbl_sign.Style.Font("Tahoma", 9, FontWeightEnum.Normal, FontStyleEnum.Normal);
            lbl_sign.Style.TextAlign = TextAlignRptEnum.Left;

            #endregion [Signature]

            #endregion [for SIGN AREA]

            #region [Juridication]

            x = 0.09; y = 0.01; wd = juridiction_rect.Width.Value - x; ht = 0.16;
            TextboxType lbl_stj = ReportUtil.AddTextbox("lbl_stj" + sufx, juridiction_rect.ReportItems, x, y, wd, ht);
            lbl_stj.Value = "Subject to Chennai Juridication";
            lbl_stj.Style.Font("Tahoma", 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_stj.Style.TextAlign = TextAlignRptEnum.Left;

            #endregion [Juridication]
        } // fn build details
Example #7
0
        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");
        }
Example #8
0
        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");
        }
Example #9
0
        private static void BuildDetail(RectangleType rectWarper)
        {
            double x = 0, y = 0, wd = 0, ht = 0;
            string sufx = "";

            x = 0.35; y = 0.32; wd = 7.65; ht = 01;
            RectangleType manirect = ReportUtil.AddRectangle("manirect" + sufx, rectWarper.ReportItems, x, y, wd, ht);

            manirect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //manirect.Style.BackgroundColor.Color = Color.Red;

            #region [rectangles]


            x = 0; y = 0; wd = wd + 0; ht = 1;
            RectangleType company_rect = ReportUtil.AddRectangle("company_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            company_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //company_rect.Style.BackgroundColor.Color = Color.Red;

            x = 0; y = ht + 0; wd = wd + 0; ht = 0.01;
            RectangleType Title_rect = ReportUtil.AddRectangle("Title_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            Title_rect.Style.BorderStyle.Default   = BorderStyleEnum.Outset;
            Title_rect.Style.BackgroundColor.Color = Color.Gray;

            x = 0; y = y + Title_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType party_rect = ReportUtil.AddRectangle("party_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            party_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //party_rect.Style.BackgroundColor.Color = Color.DarkBlue;

            x = 0; y = y + party_rect.Height.Value + 0.04; wd = wd + 0; ht = Customise.SubReportHeight;
            RectangleType items_rect = ReportUtil.AddRectangle("items_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            items_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //items_rect.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = y + items_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType subtotal_rect = ReportUtil.AddRectangle("subtotal_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            subtotal_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //subtotal_rect.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = y + subtotal_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType total_rect = ReportUtil.AddRectangle("total_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            total_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //total_rect.Style.BackgroundColor.Color = Color.Crimson;

            x = 0; y = y + total_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType grandtotal_rect = ReportUtil.AddRectangle("grandtotal_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            grandtotal_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //grandtotal_rect.Style.BackgroundColor.Color = Color.Aquamarine;

            x = 0; y = y + grandtotal_rect.Height.Value; wd = wd = wd + 0; ht = 0.1;
            RectangleType sign_rect = ReportUtil.AddRectangle("sign_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            sign_rect.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //sign_rect.Style.BackgroundColor.Color = Color.Black;

            x = 0; y = y + sign_rect.Height.Value; wd = wd = wd + 0; ht = 0.1;
            RectangleType juridiction_rect = ReportUtil.AddRectangle("juridiction_rect" + sufx, manirect.ReportItems, x, y, wd, ht);
            juridiction_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            ////juridiction_rect.Style.BackgroundColor.Color = Color.Cyan;

            #endregion [rectangles]

            #region [ Title ]

            x = 0; y = 0.01; wd = Title_rect.Width.Value; ht = 0.28;
            TextboxType txt_title = ReportUtil.AddTextbox("txtTitle" + sufx, Title_rect.ReportItems, x, y, wd, ht);
            txt_title.Value             = "=Fields!" + PPurchase.SALESTYPE + ".Value";
            txt_title.Style.TextAlign   = TextAlignRptEnum.Center;
            txt_title.Style.Color.Color = Color.White;
            txt_title.Style.Font(Customise.PrintPurchaseTitleTxt_font, 20, FontWeightEnum.Bolder, FontStyleEnum.Normal);

            x = 0; y = 0.04; wd = Title_rect.Width.Value; ht = ht + 0;
            TextboxType txt_copy = ReportUtil.AddTextbox("txtCopy" + sufx, Title_rect.ReportItems, x, y, wd, ht);
            txt_copy.Value           = "=Fields!" + PPurchase.COPIES + ".Value";
            txt_copy.Style.TextAlign = TextAlignRptEnum.Right;
            txt_copy.Style.Font(Customise.PrintPurchaseCopyTxt_font, 14, FontWeightEnum.Bolder, FontStyleEnum.Italic);
            txt_copy.Style.Color.Color = Color.White;

            #endregion [ Title ]

            #region [ COMPANY AREA]

            x = 0; y = 0; wd = 0.9; ht = Customise.companyrectHeight;
            RectangleType Company_logo = ReportUtil.AddRectangle("Company_logo" + sufx, company_rect.ReportItems, x, y, wd, ht);
            Company_logo.Style.BorderStyle.Default = BorderStyleEnum.None;
            //Company_logo.Style.BackgroundColor.Color = Color.DarkBlue;


            if (Customise.PrintPurchaseWithLogo == true)
            {
                x = wd + 0; y = 0; wd = company_rect.Width.Value - (x + 0.01); ht = ht + 0;
            }
            else
            {
                x = 0.02 + 0; y = 0; wd = company_rect.Width.Value - (x + 0.01); ht = ht + 0;
            }


            RectangleType Company_txt = ReportUtil.AddRectangle("Company_txt" + sufx, company_rect.ReportItems, x, y, wd, ht);
            Company_txt.Style.BorderStyle.Default = BorderStyleEnum.None;
            //Company_txt.Style.BackgroundColor.Color = Color.SaddleBrown;

            #region [ Company txt]

            if (Customise.PrintPurchase_PlainHeader == true)
            {
                x = 0; y = 0.05; wd = Company_txt.Width.Value - 0.02; ht = 0.4;
                TextboxType txt_compname = ReportUtil.AddTextbox("txt_compname" + sufx, Company_txt.ReportItems, x, y, wd, ht);
                txt_compname.Value = "=Fields!" + PPurchase.COMPANY_NAME + ".Value";
                txt_compname.Style.Font(Customise.PrintPurchaseHeaderCmpTxt_font, 30, FontWeightEnum.Bolder, FontStyleEnum.Normal);
                txt_compname.Style.TextAlign = TextAlignRptEnum.Center;
                //txt_compname.Style.BackgroundColor.Color = Color.Tan;

                x = 0; y = 0.50; wd = wd + 0; ht = 0.18;
                TextboxType txt_address1 = ReportUtil.AddTextbox("txt_address1" + sufx, Company_txt.ReportItems, x, y, wd, ht);
                txt_address1.Value = "=Fields!" + PPurchase.ADDRESS1 + ".Value";
                txt_address1.Style.Font(Customise.PrintPurchaseAddressCmpTxt_font, 8, FontWeightEnum.Normal, FontStyleEnum.Normal);
                txt_address1.Style.TextAlign = TextAlignRptEnum.Center;
                //txt_address1.Style.BackgroundColor.Color = Color.AntiqueWhite;

                x = 0; y = y + 0.17; wd = wd + 0; ht = 0.18;
                TextboxType txt_address2 = ReportUtil.AddTextbox("txt_address2" + sufx, Company_txt.ReportItems, x, y, wd, ht);
                txt_address2.Value = "=Fields!" + PPurchase.ADDRESS2 + ".Value";
                txt_address2.Style.Font(Customise.PrintPurchaseAddressCmpTxt_font, 8, FontWeightEnum.Normal, FontStyleEnum.Normal);
                txt_address2.Style.TextAlign = TextAlignRptEnum.Center;
                //t_address2.Style.BackgroundColor.Color = Color.SeaGreen;

                x = 0.03; y = y + 0.17; wd = wd - x; ht = 0.18;
                TextboxType txt_company_tin = ReportUtil.AddTextbox("txt_company_tin" + sufx, Company_txt.ReportItems, x, y, wd, ht);
                txt_company_tin.Value = "=Fields!" + PPurchase.COMPANY_TIN + ".Value";
                txt_company_tin.Style.Font(Customise.PrintPurchaseAddressCmpTxt_font, 8, FontWeightEnum.Normal, FontStyleEnum.Normal);
                txt_company_tin.Style.TextAlign = TextAlignRptEnum.Center;
                //txt_company_tin.Style.BackgroundColor.Color = Color.RoyalBlue;
            }

            #endregion [ Company txt]

            #endregion [ COMPANY AREA]

            #region [ Party AREA]

            x = 0; y = 0; wd = 5; ht = 0.1;
            RectangleType party_area = ReportUtil.AddRectangle("party_area" + sufx, party_rect.ReportItems, x, y, wd, ht);
            party_area.Style.BorderStyle.Default = BorderStyleEnum.None;
            party_area.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //party_area.Style.BackgroundColor.Color = Color.Green;

            x = wd; y = 0; wd = party_rect.Width.Value - wd; ht = ht + 0;
            RectangleType nodt_rect = ReportUtil.AddRectangle("nodt_rect" + sufx, party_rect.ReportItems, x, y, wd, ht);
            nodt_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //nodt_rect.Style.BackgroundColor.Color = Color.DarkOrange;

            #region [ Party - Address]

            x = 0.18; y = 0.12; wd = party_area.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType lbl_partyname = ReportUtil.AddTextbox("lbl_partyname" + sufx, party_area.ReportItems, x, y, wd, ht);
            lbl_partyname.Value = "TO.M/S.  ";
            lbl_partyname.Style.Font(Customise.PrintPurchasePartyTxt_font, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_partyname.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_partyname.Style.BackgroundColor.Color = Color.Salmon;

            x = 0.8; y = 0.08; wd = party_area.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType txt_partyname = ReportUtil.AddTextbox("txt_partyname" + sufx, party_area.ReportItems, x, y, wd, ht);
            txt_partyname.Value   = "=Fields!" + PPurchase.PARTY_NAME + ".Value";
            txt_partyname.CanGrow = true;
            txt_partyname.Style.Font(Customise.PrintPurchasePartyTxt_font, 12, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_partyname.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_partyname.Style.BackgroundColor.Color = Color.SandyBrown;

            x = x + 0; y = y + 0.20; wd = party_area.Width.Value - (x + 0.2); ht = ht + 0;
            TextboxType txt_street1 = ReportUtil.AddTextbox("txtStreet1" + sufx, party_area.ReportItems, x, y, wd, ht);
            txt_street1.CanGrow = true;
            txt_street1.Value   = "=Fields!" + PPurchase.STREET1 + ".Value";
            txt_street1.Style.Font(Customise.PrintPurchasePartyTxt_font, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_street1.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_street1.Style.BackgroundColor.Color = Color.SeaGreen;

            x = x + 0; y = y + 0.2; wd = wd + 0; ht = ht + 0;
            TextboxType txt_city = ReportUtil.AddTextbox("txt_city" + sufx, party_area.ReportItems, x, y, wd, ht);
            txt_city.Value = "=Fields!" + PPurchase.CITY + ".Value";
            txt_city.Style.Font(Customise.PrintPurchasePartyTxt_font, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_city.Style.TextAlign = TextAlignRptEnum.Left;
            txt_city.CanGrow         = true;
            //txt_city.Style.BackgroundColor.Color = Color.SkyBlue;

            x = x + 0; y = y + 0.18; wd = wd + 0; ht = ht + 0;
            TextboxType txt_tin = ReportUtil.AddTextbox("txt_tin" + sufx, party_area.ReportItems, x, y, wd, ht);
            txt_tin.Value = "=Fields!" + PPurchase.GSTIN + ".Value";
            txt_tin.Style.Font(Customise.PrintPurchasePartyTxt_font, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_tin.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_tin.Style.BackgroundColor.Color = Color.Sienna;

            #endregion [ Party - Address ]

            #region [ No - Dt ]

            x = 0.20; y = lbl_partyname.Top.Value; wd = nodt_rect.Width.Value - (x + 0.01); ht = 0.25;
            TextboxType lbl_no = ReportUtil.AddTextbox("lbl_no" + sufx, nodt_rect.ReportItems, x, y, wd, ht);
            lbl_no.Value = "No.";
            lbl_no.Style.Font(Customise.PrintPurchasePartyTxt_font, 16, FontWeightEnum.Bolder, FontStyleEnum.Normal);

            x = x + 0; y = lbl_no.Top.Value + 0.4; wd = wd + 0; ht = 0.20;
            TextboxType lbl_date = ReportUtil.AddTextbox("lbl_date" + sufx, nodt_rect.ReportItems, x, y, wd, ht);
            lbl_date.Value = "Date :";
            lbl_date.Style.Font(Customise.PrintPurchasePartyTxt_font, 12, FontWeightEnum.Normal, FontStyleEnum.Normal);

            x = 0.70; y = lbl_partyname.Top.Value - 0.001; wd = nodt_rect.Width.Value - (x + 0.01); ht = 0.25;
            TextboxType txt_no = ReportUtil.AddTextbox("txt_no" + sufx, nodt_rect.ReportItems, x, y, wd, ht);
            txt_no.Value = "=Fields!" + PPurchase.PURCHASE_NO + ".Value";
            txt_no.Style.Font(Customise.PrintPurchasePartyTxt_font, 16, FontWeightEnum.Bolder, FontStyleEnum.Normal);

            x = x + 0; y = lbl_date.Top.Value; wd = wd + 0; ht = 0.20;
            TextboxType txt_date = ReportUtil.AddTextbox("txt_date" + sufx, nodt_rect.ReportItems, x, y, wd, ht);
            txt_date.Value        = "=Fields!" + PPurchase.PURCHASE_DATE + ".Value";
            txt_date.Style.Format = "dd-MM-yyyy";
            txt_date.Style.Font(Customise.PrintPurchasePartyTxt_font, 12, FontWeightEnum.Normal, FontStyleEnum.Normal);

            #endregion [ No - Dt ]

            #endregion [Party area]

            #region [ ITEMS DETAILS AREA]

            x = 0; y = 0; wd = items_rect.Width.Value; ht = 0.1;
            ReportUtil.AddSubreport("subreport_Print_invoiceItems", "P_PurchaseItem", items_rect.ReportItems, x, y, wd, ht);

            #endregion [ ITEMS DETAILS AREA]

            #region [SUB TOTAL AREA]

            x = 0.03; y = 0.05; wd = 1.5; ht = 0.16;
            TextboxType lbl_eoe = ReportUtil.AddTextbox("lbl_eoe" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            lbl_eoe.Value = "E&OE";
            lbl_eoe.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            lbl_eoe.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_eoe.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 2.2; y = 0.03; wd = 1.35; ht = 0.16;
            TextboxType lbl_total = ReportUtil.AddTextbox("lbl_total" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            lbl_total.Value = "Total";
            lbl_total.Style.Font(Customise.PrintPurchaseBodyTxt_font, 9, FontWeightEnum.Normal, FontStyleEnum.Normal);
            lbl_total.Style.TextAlign = TextAlignRptEnum.Right;

            x = 3.85; y = 0; wd = 0.5; ht = 0.2;
            RectangleType total_qty = ReportUtil.AddRectangle("total_qty" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_qty.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_qty.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_qty.Style.BorderStyle.Right   = BorderStyleEnum.Outset;

            x = 0; y = 0.03; wd = 0.5; ht = 0.16;
            TextboxType txt_qtys = ReportUtil.AddTextbox("txt_qtys" + sufx, total_qty.ReportItems, x, y, wd, ht);
            txt_qtys.Value = "=Fields!" + PPurchase.TOTAL_QTY + ".Value";
            txt_qtys.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_qtys.Style.TextAlign = TextAlignRptEnum.Center;

            x = 4.8; y = 0; wd = 0.65; ht = 0.2;
            RectangleType total_amt = ReportUtil.AddRectangle("total_amt" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_amt.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_amt.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_amt.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //total_amt.Style.BackgroundColor.Color = Color.OrangeRed;

            x = 0; y = 0.03; wd = 0.63; ht = 0.16;
            TextboxType txt_total = ReportUtil.AddTextbox("txt_total" + sufx, total_amt.ReportItems, x, y, wd, ht);
            txt_total.Value = "=Fields!" + PPurchase.TAXABLE_VALUE + ".Value";
            txt_total.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_total.Style.TextAlign = TextAlignRptEnum.Right;

            x = 5.65; y = 0; wd = 0.55; ht = 0.2;
            RectangleType total_sgst_rect = ReportUtil.AddRectangle("total_sgst_rect" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_sgst_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_sgst_rect.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_sgst_rect.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //total_sgst_rect.Style.BackgroundColor.Color = Color.BlueViolet;

            x = 0; y = 0.03; wd = 0.52; ht = 0.16;
            TextboxType total_sgst = ReportUtil.AddTextbox("total_sgst" + sufx, total_sgst_rect.ReportItems, x, y, wd, ht);
            total_sgst.Value = "=Fields!" + PPurchase.TOTAL_SGST + ".Value";
            total_sgst.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            total_sgst.Style.TextAlign = TextAlignRptEnum.Right;

            x = 6.40; y = 0; wd = 0.55; ht = 0.2;
            RectangleType total_cgst_rec = ReportUtil.AddRectangle("total_cgst_rec" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_cgst_rec.Style.BorderStyle.Default = BorderStyleEnum.None;
            total_cgst_rec.Style.BorderStyle.Left    = BorderStyleEnum.Outset;
            total_cgst_rec.Style.BorderStyle.Right   = BorderStyleEnum.Outset;
            //total_cgst_rec.Style.BackgroundColor.Color = Color.OrangeRed;

            x = 0; y = 0.03; wd = 0.52; ht = 0.16;
            TextboxType total_cgst = ReportUtil.AddTextbox("total_cgst" + sufx, total_cgst_rec.ReportItems, x, y, wd, ht);
            total_cgst.Value = "=Fields!" + PPurchase.TOTAL_CGST + ".Value";
            total_cgst.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            total_cgst.Style.TextAlign = TextAlignRptEnum.Right;

            x = 6.92; y = 0; wd = 0.71; ht = 0.2;
            RectangleType total_sub_rec = ReportUtil.AddRectangle("total_sub_rec" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            total_sub_rec.Style.BorderStyle.Default = BorderStyleEnum.None;
            //total_sub_rec.Style.BackgroundColor.Color = Color.OrangeRed;

            x = 0; y = 0.03; wd = 0.69; ht = 0.16;
            TextboxType total_sub = ReportUtil.AddTextbox("total_sub" + sufx, total_sub_rec.ReportItems, x, y, wd, ht);
            total_sub.Value = "=Fields!" + PPurchase.TOTAL_SUB + ".Value";
            total_sub.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Normal, FontStyleEnum.Normal);
            total_sub.Style.TextAlign = TextAlignRptEnum.Right;

            //x = 4.63; y = 0; wd = items_rect.Width.Value - x; ht = 0.2;
            //RectangleType total_line = ReportUtil.AddRectangle("total_line" + sufx, subtotal_rect.ReportItems, x, y, wd, ht);
            //total_line.Style.BorderStyle.Default = BorderStyleEnum.None;
            //total_line.Style.BorderStyle.Bottom = BorderStyleEnum.Double;
            //total_line.Style.BorderStyle.Left = BorderStyleEnum.Double;
            //total_line.Style.BorderStyle.Right = BorderStyleEnum.None;

            #endregion [SUB TOTAL AREA]

            //#region [TOTAL AREA]

            #region [notes]

            x = 0; y = 0; wd = 4.5; ht = 0.6;
            RectangleType rect_notes = ReportUtil.AddRectangle("rect_notes" + sufx, total_rect.ReportItems, x, y, wd, ht);
            rect_notes.Style.BorderStyle.Default = BorderStyleEnum.None;
            //rect_notes.Style.BackgroundColor.Color = Color.OrangeRed;

            x = 0.05; y = 0.06; wd = 4.5; ht = 0.26;
            TextboxType txt_notes = ReportUtil.AddTextbox("txt_notes" + sufx, rect_notes.ReportItems, x, y, wd, ht);
            txt_notes.Value   = "=Fields!" + PPurchase.NOTES + ".Value";
            txt_notes.CanGrow = true;
            txt_notes.Style.Font(Customise.PrintPurchaseBodyTxt_font, 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_notes.Style.TextAlign = TextAlignRptEnum.Left;

            #endregion [notes]

            #region [Labels]

            x = 4.88; y = 0; wd = 2.72; ht = 0.1;
            RectangleType rect_totallbl = ReportUtil.AddRectangle("rect_totallbl" + sufx, total_rect.ReportItems, x, y, wd, ht);
            rect_totallbl.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //rect_totallbl.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0; wd = 2.72; ht = 0.01;
            RectangleType bx_1 = ReportUtil.AddRectangle("bx_1" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_1.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_1.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_taxablevalue = ReportUtil.AddTextbox("lbl_taxablevalue" + sufx, bx_1.ReportItems, x, y, wd, ht);
            lbl_taxablevalue.Value = "  Taxable Value";
            lbl_taxablevalue.Style.Font(Customise.PrintPurchaseBodyTxt_font, 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_taxablevalue.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_taxablevalue.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_taxablevalue.Top.Value; wd = 0.82; ht = 0.12;
            TextboxType txt_taxable_amt = ReportUtil.AddTextbox("txt_taxable_amt" + sufx, bx_1.ReportItems, x, y, wd, ht);
            txt_taxable_amt.Value = "=Fields!" + PPurchase.TAXABLE_VALUE + ".Value";
            txt_taxable_amt.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_taxable_amt.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_taxable_amt.Style.BackgroundColor.Color = Color.White;


            x = 0; y = 0.01; wd = 2.72; ht = 0.01;
            RectangleType bx_2 = ReportUtil.AddRectangle("bx_2" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_2.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_2.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_Sgst = ReportUtil.AddTextbox("lbl_Sgst" + sufx, bx_2.ReportItems, x, y, wd, ht);
            lbl_Sgst.Value = "=Fields!" + PPurchase.LBL_SGST + ".Value";
            lbl_Sgst.Style.Font(Customise.PrintPurchaseBodyTxt_font, 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_Sgst.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_Sgst.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_Sgst.Top.Value; wd = 0.82; ht = 0.12;
            TextboxType txt_Sgst = ReportUtil.AddTextbox("txt_Sgst" + sufx, bx_2.ReportItems, x, y, wd, ht);
            txt_Sgst.Value = "=Fields!" + PPurchase.TOTAL_SGST + ".Value";
            txt_Sgst.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_Sgst.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_Sgst.Style.BackgroundColor.Color = Color.White;


            x = 0; y = 0.02; wd = 2.72; ht = 0.01;
            RectangleType bx_3 = ReportUtil.AddRectangle("bx_3" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_3.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_3.Style.BackgroundColor.Color = Color.MistyRose;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_cgst = ReportUtil.AddTextbox("lbl_cgst" + sufx, bx_3.ReportItems, x, y, wd, ht);
            lbl_cgst.Value = "=Fields!" + PPurchase.LBL_CGST + ".Value";
            lbl_cgst.Style.Font(Customise.PrintPurchaseBodyTxt_font, 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_cgst.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_cgst.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_cgst.Top.Value; wd = 0.82; ht = 0.12;
            TextboxType txt_cgst = ReportUtil.AddTextbox("txt_cgst" + sufx, bx_3.ReportItems, x, y, wd, ht);
            txt_cgst.Value = "=Fields!" + PPurchase.TOTAL_CGST + ".Value";
            txt_cgst.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_cgst.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_cgst.Style.BackgroundColor.Color = Color.White;

            x = 0; y = 0.03; wd = 2.72; ht = 0.01;
            RectangleType bx_4 = ReportUtil.AddRectangle("bx_4" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_1.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_1.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_GSTTotal = ReportUtil.AddTextbox("lbl_GSTTotal" + sufx, bx_4.ReportItems, x, y, wd, ht);
            lbl_GSTTotal.Value = "  TOTAL GST TAX ";
            lbl_GSTTotal.Style.Font(Customise.PrintPurchaseBodyTxt_font, 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_GSTTotal.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_GSTTotal.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_GSTTotal.Top.Value; wd = 0.82; ht = 0.12;
            TextboxType txt_GSTTotal = ReportUtil.AddTextbox("txt_GSTTotal" + sufx, bx_4.ReportItems, x, y, wd, ht);
            txt_GSTTotal.Value = "=Fields!" + PPurchase.GSTTOTAL + ".Value";
            txt_GSTTotal.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_GSTTotal.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_GSTTotal.Style.BackgroundColor.Color = Color.White;


            x = 0; y = 0.04; wd = 2.72; ht = 0.01;
            RectangleType bx_5 = ReportUtil.AddRectangle("bx_5" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_1.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_1.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType txt_ledger = ReportUtil.AddTextbox("txt_ledger" + sufx, bx_5.ReportItems, x, y, wd, ht);
            txt_ledger.Value = "=Fields!" + PPurchase.LEDGER + ".Value";
            txt_ledger.Style.Font(Customise.PrintPurchaseBodyTxt_font, 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_ledger.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_ledger.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = txt_ledger.Top.Value; wd = 0.82; ht = 0.12;
            TextboxType txt_additional = ReportUtil.AddTextbox("txt_additional" + sufx, bx_5.ReportItems, x, y, wd, ht);
            txt_additional.Value = "=Fields!" + PPurchase.ADDITIONAL + ".Value";
            txt_additional.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_additional.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_additional.Style.BackgroundColor.Color = Color.White;


            x = 0; y = 0.05; wd = 2.72; ht = 0.01;
            RectangleType bx_6 = ReportUtil.AddRectangle("bx_6" + sufx, rect_totallbl.ReportItems, x, y, wd, ht);
            bx_1.Style.BorderStyle.Default = BorderStyleEnum.Solid;
            //bx_1.Style.BackgroundColor.Color = Color.Tan;

            x = 0; y = 0.03; wd = 1.8; ht = 0.18;
            TextboxType lbl_round = ReportUtil.AddTextbox("lbl_round" + sufx, bx_6.ReportItems, x, y, wd, ht);
            lbl_round.Value = "  Round off ";
            lbl_round.Style.Font(Customise.PrintPurchaseBodyTxt_font, 8, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_round.Style.TextAlign = TextAlignRptEnum.Left;
            //lbl_round.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 1.85; y = lbl_round.Top.Value; wd = 0.82; ht = 0.12;
            TextboxType txt_round = ReportUtil.AddTextbox("txt_round" + sufx, bx_6.ReportItems, x, y, wd, ht);
            txt_round.Value = "=Fields!" + PPurchase.ROUNDS + ".Value";
            txt_round.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_round.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_round.Style.BackgroundColor.Color = Color.Beige;

            #endregion [total field]

            #region [Grand total]

            x = 0; y = 0; wd = 4.93; ht = 0.45;
            RectangleType amtnwords = ReportUtil.AddRectangle("amtnwords" + sufx, grandtotal_rect.ReportItems, x, y, wd, ht);
            amtnwords.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //amtnwords.Style.BackgroundColor.Color = Color.Red;

            x = 0.05; y = 0.01; wd = 4.7; ht = 0.4;
            TextboxType txt_amtnwords = ReportUtil.AddTextbox("txt_amtnwords" + sufx, amtnwords.ReportItems, x, y, wd, ht);
            txt_amtnwords.Value   = "=Fields!" + PPurchase.AMOUNT_IN_WORDS + ".Value";
            txt_amtnwords.CanGrow = true;
            txt_amtnwords.Style.Font(Customise.PrintPurchaseBodyTxt_font, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_amtnwords.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_amtnwords.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 4.93; y = 0.08; wd = 1.3; ht = 0.28;
            TextboxType lbl_grandtotal = ReportUtil.AddTextbox("lbl_grandtotal" + sufx, grandtotal_rect.ReportItems, x, y, wd, ht);
            lbl_grandtotal.Value = "  GRAND TOTAL";
            lbl_grandtotal.Style.Font(Customise.PrintPurchaseBodyTxt_font, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_grandtotal.Style.TextAlign = TextAlignRptEnum.Left;
            // lbl_grandtotal.Style.BackgroundColor.Color = Color.DeepSkyBlue;
            //lbl_grandtotal.Style.BorderStyle.Left = BorderStyleEnum.Outset;

            x = 6.20; y = 0.08; wd = 1.43; ht = 0.28;
            TextboxType txt_grandtotal = ReportUtil.AddTextbox("txt_grandtotal" + sufx, grandtotal_rect.ReportItems, x, y, wd, ht);
            txt_grandtotal.Value = "=Fields!" + PPurchase.GRANDTOTAL + ".Value";
            txt_grandtotal.Style.Font(Customise.PrintPurchaseBodyTxt_font, 12, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_grandtotal.Style.TextAlign = TextAlignRptEnum.Right;
            // txt_grandtotal.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [Grand total]

            //#endregion [TOTAL AREA]

            #region [for SIGN AREA]

            #region [amounts in words]
            x = 0; y = 0; wd = 4.5; ht = 0.5;
            RectangleType receiver_rect = ReportUtil.AddRectangle("receiver_rect" + sufx, sign_rect.ReportItems, x, y, wd, ht);
            receiver_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //amtnwords.Style.BackgroundColor.Color = Color.Red;

            x = 0.05; y = 0.08; wd = wd - 0.2; ht = 0.18;
            TextboxType txt_receiversign = ReportUtil.AddTextbox("txt_receiversign" + sufx, receiver_rect.ReportItems, x, y, wd, ht);
            txt_receiversign.Value = "Receiver Signature";
            //txt_receiversign.CanGrow = true;
            txt_receiversign.Style.Font(Customise.PrintPurchaseBodyTxt_font, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_receiversign.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_receiversign.Style.BackgroundColor.Color = Color.Violet;

            #endregion [amounts in words]

            #region [Signature]

            x = amtnwords.Width.Value; y = 0; wd = 2.72; ht = 0.95;
            RectangleType forspace = ReportUtil.AddRectangle("forspace" + sufx, sign_rect.ReportItems, x, y, wd, ht);
            forspace.Style.BorderStyle.Default = BorderStyleEnum.Outset;
            //forspace.Style.BackgroundColor.Color = Color.Violet;

            x = 0.05; y = 0.06; wd = 2.4; ht = 0.16;
            TextboxType lbl_for = ReportUtil.AddTextbox("lbl_for" + sufx, forspace.ReportItems, x, y, wd, ht);
            lbl_for.Value = "For";
            lbl_for.Style.Font(Customise.PrintPurchaseFORTxt_font, 9, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_for.Style.TextAlign = TextAlignRptEnum.Left;

            x = x + 0.3; y = 0.04; wd = 2.7 - x; ht = 0.20;
            TextboxType lbl_forcompany = ReportUtil.AddTextbox("lbl_forcompany" + sufx, forspace.ReportItems, x, y, wd, ht);
            lbl_forcompany.Value = "=Fields!COMPANY_NAME.Value";
            lbl_forcompany.Style.Font(Customise.PrintPurchaseFORTxt_font, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_forcompany.Style.TextAlign = TextAlignRptEnum.Left;

            x = lbl_for.Left.Value + 0.2; y = 0.70; wd = 2.7 - x; ht = 0.15;
            TextboxType lbl_sign = ReportUtil.AddTextbox("lbl_sign" + sufx, forspace.ReportItems, x, y, wd, ht);
            lbl_sign.Value = "    Authorized signatory";
            lbl_sign.Style.Font(Customise.PrintPurchaseBodyTxt_font, 9, FontWeightEnum.Normal, FontStyleEnum.Normal);
            lbl_sign.Style.TextAlign = TextAlignRptEnum.Left;

            #endregion [Signature]

            #endregion [for SIGN AREA]

            #region [Juridication]

            if (Customise.PrintJuridication == true)
            {
                x = 0.09; y = 0.01; wd = juridiction_rect.Width.Value - x; ht = 0.16;
                TextboxType lbl_stj = ReportUtil.AddTextbox("lbl_stj" + sufx, juridiction_rect.ReportItems, x, y, wd, ht);
                lbl_stj.Value = "Subject to " + Customise.JuridicationTxt + " Juridication";
                lbl_stj.Style.Font(Customise.PrintPurchaseBodyTxt_font, 7, FontWeightEnum.Bolder, FontStyleEnum.Normal);
                lbl_stj.Style.TextAlign = TextAlignRptEnum.Left;
            }
            #endregion [Juridication]
        } // fn build details
Example #10
0
        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
Example #11
0
        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]
        }
Example #12
0
        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
Example #13
0
        }// fn build details

        #region [Lines AREA]

        private static void Sub_rectangle_position(CXSubRectangles rct)
        {
            RectangleType subrect = rct.subrect;
            string        sufx = rct.sufx;
            double        x = 0, y = 0, wd = 0.23, ht = Customised.SubReportHeight;

            rct.Slno = ReportUtil.AddRectangle("slno" + sufx, subrect.ReportItems, x, y, wd, ht);


            // if true show po and dc or hsncode to front

            if (Customised.WithPo)
            {
                rct.Po = ReportUtil.AddRectangle("po" + sufx, subrect.ReportItems, x += rct.Slno.Width.Value, 0, 0.45, ht);
                rct.Dc = ReportUtil.AddRectangle("dc" + sufx, subrect.ReportItems, x += rct.Po.Width.Value, 0, 0.45, ht);

                x += rct.Dc.Width.Value;
            }
            else
            {
                x += rct.Slno.Width.Value;
            }

            rct.Hsn_code = ReportUtil.AddRectangle("hsn_code" + sufx, subrect.ReportItems, x, 0, 0.45, ht);


            //for particulars

            if (Customised.WithPo)
            {
                if (Customised.WithColours)
                {
                    if (Customised.WithSizes)
                    {
                        //po true size true colour true
                        switch (Customised.TaxType)
                        {
                        case Core.SGST:
                            x += rct.Hsn_code.Width.Value; wd = 1;
                            break;

                        case Core.IGST:
                            x += rct.Hsn_code.Width.Value; wd = 1.5;
                            break;
                        }
                    }
                    else
                    {
                        //po true size false colour true
                        switch (Customised.TaxType)
                        {
                        case Core.SGST:
                            x += rct.Hsn_code.Width.Value; wd = 1.39;
                            break;

                        case Core.IGST:
                            x += rct.Hsn_code.Width.Value; wd = 2;
                            break;
                        }
                    }
                }
                else
                {
                    if (Customised.WithSizes)
                    {
                        // po True colour false size true
                        switch (Customised.TaxType)
                        {
                        case Core.SGST:
                            x += rct.Hsn_code.Width.Value; wd = 1.49;
                            break;

                        case Core.IGST:
                            x += rct.Hsn_code.Width.Value; wd = 2;
                            break;
                        }
                    }
                    else
                    {
                        //po true size false colour false
                        switch (Customised.TaxType)
                        {
                        case Core.SGST:
                            x += rct.Hsn_code.Width.Value; wd = 1.99;
                            break;

                        case Core.IGST:
                            x += rct.Hsn_code.Width.Value; wd = 2.49;
                            break;
                        }
                    }
                }
            }
            else
            {
                if (Customised.WithColours)
                {
                    if (Customised.WithSizes)
                    {
                        //po false size true colour true
                        switch (Customised.TaxType)
                        {
                        case Core.SGST:
                            x += rct.Hsn_code.Width.Value; wd = 1.89;
                            break;

                        case Core.IGST:
                            x += rct.Hsn_code.Width.Value; wd = 2.39;
                            break;
                        }
                    }
                    else
                    {
                        //po false size false colour true
                        switch (Customised.TaxType)
                        {
                        case Core.SGST:
                            x += rct.Hsn_code.Width.Value; wd = 2.39;
                            break;

                        case Core.IGST:
                            x += rct.Hsn_code.Width.Value; wd = 2.89;
                            break;
                        }
                    }
                }
                else
                {
                    if (Customised.WithSizes)
                    {
                        // po false colour false size true
                        switch (Customised.TaxType)
                        {
                        case Core.SGST:
                            x += rct.Hsn_code.Width.Value; wd = 2.39;
                            break;

                        case Core.IGST:
                            x += rct.Hsn_code.Width.Value; wd = 2.89;
                            break;
                        }
                    }
                    else
                    {
                        //po false size false colour false
                        switch (Customised.TaxType)
                        {
                        case Core.SGST:
                            x += rct.Hsn_code.Width.Value; wd = 2.89;
                            break;

                        case Core.IGST:
                            x += rct.Hsn_code.Width.Value; wd = 3.39;
                            break;
                        }
                    }
                }
            }


            rct.Particulars = ReportUtil.AddRectangle("particulars" + sufx, subrect.ReportItems, x, 0, wd, ht);

            x += rct.Particulars.Width.Value;

            if (Customised.WithSizes)
            {
                rct.Sizes = ReportUtil.AddRectangle("sizes" + sufx, subrect.ReportItems, x, 0, 0.5, ht);

                x += rct.Sizes.Width.Value;
            }


            if (Customised.WithColours)
            {
                rct.Colours = ReportUtil.AddRectangle("colours" + sufx, subrect.ReportItems, x, 0, 0.5, ht);

                x += rct.Colours.Width.Value;
            }
            //else
            //{
            //    if (!Customised.WithSizes)
            //    {
            //        x += rct.Particulars.Width.Value;
            //    }
            //}

            rct.Qtys       = ReportUtil.AddRectangle("qtys" + sufx, subrect.ReportItems, x, 0, 0.52, ht);
            rct.Price      = ReportUtil.AddRectangle("price" + sufx, subrect.ReportItems, x += rct.Qtys.Width.Value, 0, 0.57, ht);
            rct.Taxableamt = ReportUtil.AddRectangle("taxableamt" + sufx, subrect.ReportItems, x += rct.Price.Width.Value, 0, 0.75, ht);

            if (Customised.TaxType == Core.SGST)
            {
                rct.Sgst_per = ReportUtil.AddRectangle("sgst_per" + sufx, subrect.ReportItems, x += rct.Taxableamt.Width.Value, 0.3, 0.2, ht - 0.3);
                rct.Sgst_amt = ReportUtil.AddRectangle("sgst_amt" + sufx, subrect.ReportItems, x += rct.Sgst_per.Width.Value, 0, 0.55, ht);

                rct.Cgst_per = ReportUtil.AddRectangle("cgst_per" + sufx, subrect.ReportItems, x += rct.Sgst_amt.Width.Value, 0.3, 0.2, ht - 0.3);

                rct.Cgst_amt = ReportUtil.AddRectangle("cgst_amt" + sufx, subrect.ReportItems, x += rct.Cgst_per.Width.Value, 0, 0.55, ht);

                x += rct.Cgst_amt.Width.Value;
            }
            else if (Customised.TaxType == Core.IGST)
            {
                rct.Igst_per = ReportUtil.AddRectangle("igst_per" + sufx, subrect.ReportItems, x += rct.Taxableamt.Width.Value, 0.3, 0.25, ht - 0.3);
                rct.Igst_amt = ReportUtil.AddRectangle("igst_amt" + sufx, subrect.ReportItems, x += rct.Igst_per.Width.Value, 0, 0.752, ht);

                x += rct.Igst_amt.Width.Value;
            }

            rct.Sub_total = ReportUtil.AddRectangle("sub_total" + sufx, subrect.ReportItems, x, 0, 0.74, ht);

            Style(rct.Slno);
            Style(rct.Po);
            Style(rct.Dc);
            Style(rct.Particulars);
            Style(rct.Sizes);
            Style(rct.Colours);
            Style(rct.Qtys);
            Style(rct.Price);
            Style(rct.Taxableamt);
            Style(rct.Sgst_per);
            Style(rct.Sgst_amt);
            Style(rct.Cgst_per);
            Style(rct.Cgst_amt);
            Style(rct.Igst_per);
            Style(rct.Igst_amt);
            Style(rct.Sub_total);

            //rct.Slno.Style.BackgroundColor.Color = Color.Aquamarine;
            //rct.Po.Style.BackgroundColor.Color = Color.DarkRed;
            //rct.Dc.Style.BackgroundColor.Color = Color.Green;
            //rct.Hsn_code.Style.BackgroundColor.Color = Color.Blue;
            //rct.Particulars.Style.BackgroundColor.Color = Color.Yellow;
            //rct.Sizes.Style.BackgroundColor.Color = Color.Lime;
            //rct.Colours.Style.BackgroundColor.Color = Color.LightBlue;
            //rct.Qtys.Style.BackgroundColor.Color = Color.LightCoral;
            //rct.Price.Style.BackgroundColor.Color = Color.LemonChiffon;
            //rct.Taxableamt.Style.BackgroundColor.Color = Color.LightSalmon;
            //rct.Cgst_per.Style.BackgroundColor.Color = Color.White;
            //rct.Cgst_amt.Style.BackgroundColor.Color = Color.Beige;
            //rct.Sgst_per.Style.BackgroundColor.Color = Color.Khaki;
            //rct.Sgst_amt.Style.BackgroundColor.Color = Color.Azure;
            //rct.Igst_per.Style.BackgroundColor.Color = Color.AntiqueWhite;
            //rct.Igst_amt.Style.BackgroundColor.Color = Color.AliceBlue;
            //rct.Sub_total.Style.BackgroundColor.Color = Color.LightGreen;
        }
Example #14
0
        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);
        }
Example #15
0
        private static void BuildDetail(RectangleType rectWarper)
        {
            double x = 0, y = 0, wd = 0, ht = 0;


            #region [rect]

            x = 0.35; y = 0.20; wd = 7.65; ht = 01;
            RectangleType manirect = ReportUtil.AddRectangle("manirect", rectWarper.ReportItems, x, y, wd, ht);
            manirect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //manirect.Style.BackgroundColor.Color = Color.Red;

            x = 0; y = 0; wd = wd + 0; ht = 5.6;
            RectangleType rect_1   = ReportUtil.AddRectangle("rect_1", manirect.ReportItems, x, y, wd, ht);
            rect_1.Style.BorderStyle.Default = BorderStyleEnum.None;
            //rect_1.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = 0; wd = wd + 0; ht = 0.01;
            RectangleType title_rect = ReportUtil.AddRectangle("title_rect", rect_1.ReportItems, x, y, wd, ht);
            title_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //title_rect.Style.BackgroundColor.Color = Color.Orange;

            x = 0; y = y + title_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType party_rect = ReportUtil.AddRectangle("party_rect", rect_1.ReportItems, x, y, wd, ht);
            party_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //party_rect.Style.BackgroundColor.Color = Color.Blue;

            x = 0; y = y + party_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType items_rect = ReportUtil.AddRectangle("items_rect", rect_1.ReportItems, x, y, wd, ht);
            items_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            items_rect.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //items_rect.Style.BackgroundColor.Color = Color.Green;

            x = 0; y = y + items_rect.Height.Value; wd = wd + 0; ht = 0.01;
            RectangleType ledger_rect = ReportUtil.AddRectangle("ledger_rect", rect_1.ReportItems, x, y, wd, ht);
            ledger_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            ledger_rect.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //ledger_rect.Style.BackgroundColor.Color = Color.Red;

            x = 0; y = y + ledger_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType grandtotal_rect = ReportUtil.AddRectangle("grandtotal_rect", rect_1.ReportItems, x, y, wd, ht);
            grandtotal_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            grandtotal_rect.Style.BorderStyle.Bottom  = BorderStyleEnum.Outset;
            //grandtotal_rect.Style.BackgroundColor.Color = Color.Aquamarine;

            x = 0; y = y + grandtotal_rect.Height.Value; wd = wd + 0; ht = 0.1;
            RectangleType Sign_rect = ReportUtil.AddRectangle("Sign_rect", rect_1.ReportItems, x, y, wd, ht);
            Sign_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //Sign_rect.Style.BackgroundColor.Color = Color.Aquamarine;

            #endregion [rect]

            #region [Title]

            x = 0; y = 0.01; wd = title_rect.Width.Value; ht = 0.30;
            TextboxType txt_title = ReportUtil.AddTextbox("txt_title", title_rect.ReportItems, x, y, wd, ht);
            txt_title.Value           = "DELIVERY NOTE";
            txt_title.Style.TextAlign = TextAlignRptEnum.Center;
            txt_title.Style.Font(Customised.TitleTxtFont, 16, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_title.Style.TextDecoration = TextDecorationEnum.Underline;

            #endregion [Title]

            #region [party]

            x = 0; y = 0; wd = 5; ht = 0.1;
            RectangleType party_area = ReportUtil.AddRectangle("party_area", party_rect.ReportItems, x, y, wd, ht);
            party_area.Style.BorderStyle.Default = BorderStyleEnum.None;
            //party_area.Style.BackgroundColor.Color = Color.Green;

            x = wd; y = 0; wd = party_rect.Width.Value - wd; ht = ht + 0;
            RectangleType nodt_rect = ReportUtil.AddRectangle("nodt_rect", party_rect.ReportItems, x, y, wd, ht);
            nodt_rect.Style.BorderStyle.Default = BorderStyleEnum.None;
            //nodt_rect.Style.BackgroundColor.Color = Color.DarkOrange;


            x = 2.5; y = 0.08; wd = party_area.Width.Value - (x + 0.2); ht = 0.20;
            TextboxType txt_partyname = ReportUtil.AddTextbox("txt_partyname", party_area.ReportItems, x, y, wd, ht);
            txt_partyname.Value   = "=Fields!" + POUTWARD.PARTY_NAME + ".Value";
            txt_partyname.CanGrow = true;
            txt_partyname.Style.Font(Customised.PartyTxtFont, 12, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            txt_partyname.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_partyname.Style.BackgroundColor.Color = Color.SandyBrown;

            x = x + 0; y = y + 0.2; wd = wd + 0; ht = ht + 0;
            TextboxType txt_city = ReportUtil.AddTextbox("txt_city", party_area.ReportItems, x, y, wd, ht);
            txt_city.Value = "=Fields!" + POUTWARD.CITY + ".Value";
            txt_city.Style.Font(Customised.PartyTxtFont, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_city.Style.TextAlign = TextAlignRptEnum.Left;
            txt_city.CanGrow         = true;
            //txt_city.Style.BackgroundColor.Color = Color.SkyBlue;

            x = 0.20; y = txt_partyname.Top.Value; wd = nodt_rect.Width.Value - (x + 0.01); ht = 0.25;
            TextboxType txt_no = ReportUtil.AddTextbox("txt_no", nodt_rect.ReportItems, x, y, wd, ht);
            txt_no.Value = "=Fields!" + POUTWARD.OUTWARD_NO + ".Value";
            txt_no.Style.Font(Customised.PartyTxtFont, 12, FontWeightEnum.Normal, FontStyleEnum.Normal);

            x = x + 0; y = y + 0.25; wd = wd + 0; ht = 0.20;
            TextboxType txt_date = ReportUtil.AddTextbox("txt_date", nodt_rect.ReportItems, x, y, wd, ht);
            txt_date.Value        = "=Fields!" + POUTWARD.OUTWARD_DATE + ".Value";
            txt_date.Style.Format = "dd-MM-yyyy";
            txt_date.Style.Font(Customised.PartyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);

            #endregion [party]

            #region [sub]

            x = 0; y = 0; wd = items_rect.Width.Value; ht = 0.1;
            ReportUtil.AddSubreport("subreport_Print_OutwardItem", "P_OutwardItem", items_rect.ReportItems, x, y, wd, ht);

            #endregion [sub]

            #region [Ledger]

            x = 4.8; y = 0.01; wd = 2; ht = 0.18;
            TextboxType txt_ledger = ReportUtil.AddTextbox("txt_ledger", ledger_rect.ReportItems, x, y, wd, ht);
            txt_ledger.Value = "TOTAL QTY : ";
            txt_ledger.Style.Font(Customised.BodyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_ledger.Style.TextAlign = TextAlignRptEnum.Left;
            //txt_ledger.Style.BackgroundColor.Color = Color.DeepSkyBlue;

            x = 6.3; y = txt_ledger.Top.Value; wd = 1.33; ht = 0.18;
            TextboxType txt_additional = ReportUtil.AddTextbox("txt_additional", ledger_rect.ReportItems, x, y, wd, ht);
            txt_additional.Value = "=Fields!" + POUTWARD.TOTAL_QTY + ".Value";
            txt_additional.Style.Font(Customised.BodyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_additional.Style.TextAlign = TextAlignRptEnum.Right;
            //txt_additional.Style.BackgroundColor.Color = Color.Tan;

            #endregion [Ledger]

            #region [Grand total]

            x = 4.8; y = 0.01; wd = 1.3; ht = 0.19;
            TextboxType lbl_grandtotal = ReportUtil.AddTextbox("lbl_grandtotal", grandtotal_rect.ReportItems, x, y, wd, ht);
            lbl_grandtotal.Value = "No of Bundles";
            lbl_grandtotal.Style.Font(Customised.BodyTxtFont, 10, FontWeightEnum.Bolder, FontStyleEnum.Normal);
            lbl_grandtotal.Style.TextAlign = TextAlignRptEnum.Left;

            x = 6.3; y = 0.01; wd = 1.43; ht = 0.19;
            TextboxType txt_grandtotal = ReportUtil.AddTextbox("txt_grandtotal", grandtotal_rect.ReportItems, x, y, wd, ht);
            txt_grandtotal.Value = "=Fields!" + POUTWARD.TOTAL_BUNDLE + ".Value";
            txt_grandtotal.Style.Font(Customised.BodyTxtFont, 11, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_grandtotal.Style.TextAlign = TextAlignRptEnum.Right;

            #endregion [Grand total]

            #region [sign]

            x = 0; y = 0.08; wd = Sign_rect.Width.Value - 0.8; ht = 0.28;
            TextboxType txt_forsign = ReportUtil.AddTextbox("txt_forsign", Sign_rect.ReportItems, x, y, wd, ht);
            txt_forsign.Value = "Recevier Sign                                Prepared by                                               Party Sign";
            txt_forsign.Style.Font(Customised.BodyTxtFont, 10, FontWeightEnum.Normal, FontStyleEnum.Normal);
            txt_forsign.Style.TextAlign = TextAlignRptEnum.Center;
            //txt_forsign.Style.BackgroundColor.Color = Color.Tomato;

            #endregion [sign]
        } // fn build details
Example #16
0
        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