OBJECT Report 206 Sales - Invoice { OBJECT-PROPERTIES { Date=22/05/12; Time=22:49:58; Modified=Yes; Version List=NAVW16.00.01,NAVBE4.00.01,PS237277; } PROPERTIES { Permissions=TableData 7190=rimd; CaptionML=[ENU=Sales - Invoice; FRB=Ventes : Facture; NLB=Verkoop - Factuur]; OnInitReport=BEGIN GLSetup.GET; CompanyInfo.GET; SalesSetup.GET; CASE SalesSetup."Logo Position on Documents" OF SalesSetup."Logo Position on Documents"::"No Logo":; SalesSetup."Logo Position on Documents"::Left: BEGIN CompanyInfo.CALCFIELDS(Picture); END; SalesSetup."Logo Position on Documents"::Center: BEGIN CompanyInfo1.GET; CompanyInfo1.CALCFIELDS(Picture); END; SalesSetup."Logo Position on Documents"::Right: BEGIN CompanyInfo2.GET; CompanyInfo2.CALCFIELDS(Picture); END; END; END; OnPreReport=BEGIN IF NOT CurrReport.USEREQUESTFORM THEN InitLogInteraction; END; HorzGrid=210; } DATAITEMS { { PROPERTIES { DataItemTable=Table112; DataItemTableView=SORTING(No.); NewPagePerRecord=Yes; ReqFilterHeadingML=[ENU=Posted Sales Invoice; FRB=Facture vente enregistr‚e; NLB=Geboekte verkoopfactuur]; OnAfterGetRecord=BEGIN VATNoText := ''; NoText := ''; CurrReport.LANGUAGE := Language.GetLanguageID("Language Code"); IF RespCenter.GET("Responsibility Center") THEN BEGIN FormatAddr.RespCenter(CompanyAddr,RespCenter); CompanyInfo."Phone No." := RespCenter."Phone No."; CompanyInfo."Fax No." := RespCenter."Fax No."; END ELSE BEGIN FormatAddr.Company(CompanyAddr,CompanyInfo); END; PostedDocDim1.SETRANGE("Table ID",DATABASE::"Sales Invoice Header"); PostedDocDim1.SETRANGE("Document No.","Sales Invoice Header"."No."); IF "Order No." = '' THEN OrderNoText := '' ELSE OrderNoText := FIELDCAPTION("Order No."); IF "Salesperson Code" = '' THEN BEGIN SalesPurchPerson.INIT; SalesPersonText := ''; END ELSE BEGIN SalesPurchPerson.GET("Salesperson Code"); SalesPersonText := Text000; END; IF "Your Reference" = '' THEN ReferenceText := '' ELSE ReferenceText := FIELDCAPTION("Your Reference"); IF NOT Country.DetermineCountry("Bill-to Country/Region Code") THEN BEGIN IF "VAT Registration No." <> '' THEN BEGIN VATNoText := FIELDCAPTION("VAT Registration No."); NoText := "VAT Registration No."; END END ELSE IF "Enterprise No." <> '' THEN BEGIN VATNoText := FIELDCAPTION("Enterprise No."); NoText := "Enterprise No."; END; IF "Currency Code" = '' THEN BEGIN GLSetup.TESTFIELD("LCY Code"); TotalText := STRSUBSTNO(Text001,GLSetup."LCY Code"); TotalInclVATText := STRSUBSTNO(Text002,GLSetup."LCY Code"); TotalExclVATText := STRSUBSTNO(Text006,GLSetup."LCY Code"); END ELSE BEGIN TotalText := STRSUBSTNO(Text001,"Currency Code"); TotalInclVATText := STRSUBSTNO(Text002,"Currency Code"); TotalExclVATText := STRSUBSTNO(Text006,"Currency Code"); END; FormatAddr.SalesInvBillTo(CustAddr,"Sales Invoice Header"); IF NOT Cust.GET("Bill-to Customer No.") THEN CLEAR(Cust); IF "Payment Terms Code" = '' THEN PaymentTerms.INIT ELSE BEGIN PaymentTerms.GET("Payment Terms Code"); PaymentTerms.TranslateDescription(PaymentTerms,"Language Code"); END; IF "Shipment Method Code" = '' THEN ShipmentMethod.INIT ELSE BEGIN ShipmentMethod.GET("Shipment Method Code"); ShipmentMethod.TranslateDescription(ShipmentMethod,"Language Code"); END; FormatAddr.SalesInvShipTo(ShipToAddr,"Sales Invoice Header"); ShowShippingAddr := "Sell-to Customer No." <> "Bill-to Customer No."; FOR i := 1 TO ARRAYLEN(ShipToAddr) DO IF ShipToAddr[i] <> CustAddr[i] THEN ShowShippingAddr := TRUE; IF LogInteraction THEN IF NOT CurrReport.PREVIEW THEN BEGIN IF "Bill-to Contact No." <> '' THEN SegManagement.LogDocument( 4,"No.",0,0,DATABASE::Contact,"Bill-to Contact No.","Salesperson Code", "Campaign No.","Posting Description",'') ELSE SegManagement.LogDocument( 4,"No.",0,0,DATABASE::Customer,"Bill-to Customer No.","Salesperson Code", "Campaign No.","Posting Description",''); END; END; ReqFilterFields=No.,Sell-to Customer No.,No. Printed; } SECTIONS { } } { PROPERTIES { DataItemIndent=1; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number); NewPagePerRecord=Yes; DataItemVarName=CopyLoop; OnPreDataItem=BEGIN NoOfLoops := ABS(NoOfCopies) + Cust."Invoice Copies" + 1; IF NoOfLoops <= 0 THEN NoOfLoops := 1; CopyText := ''; SETRANGE(Number,1,NoOfLoops); IF ISSERVICETIER THEN OutputNo := 1; END; OnAfterGetRecord=BEGIN IF Number > 1 THEN BEGIN CopyText := Text003; IF ISSERVICETIER THEN OutputNo += 1; END; CurrReport.PAGENO := 1; IF ISSERVICETIER THEN BEGIN TotalSubTotal := 0; TotalInvoiceDiscountAmount := 0; TotalAmount := 0; TotalAmountVAT := 0; TotalAmountInclVAT := 0; TotalPaymentDiscountOnVAT := 0; END END; OnPostDataItem=BEGIN IF NOT CurrReport.PREVIEW THEN SalesInvCountPrinted.RUN("Sales Invoice Header"); END; } SECTIONS { } } { PROPERTIES { DataItemIndent=2; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number) WHERE(Number=CONST(1)); DataItemVarName=PageLoop; } SECTIONS { { PROPERTIES { SectionType=Header; PrintOnEveryPage=Yes; SectionWidth=18060; SectionHeight=9729; } CONTROLS { { 149 ;PictureBox ;11550;0 ;6160 ;3960 ;SourceExpr=CompanyInfo2.Picture; DataSetFieldName=CompanyInfo2_Picture } { 148 ;PictureBox ;5460 ;0 ;6160 ;3960 ;SourceExpr=CompanyInfo1.Picture; DataSetFieldName=CompanyInfo1_Picture } { 147 ;PictureBox ;0 ;0 ;6160 ;3960 ;SourceExpr=CompanyInfo.Picture; DataSetFieldName=CompanyInfo_Picture } { 1 ;TextBox ;11550;0 ;6300 ;423 ;FontSize=10; FontBold=Yes; SourceExpr=STRSUBSTNO(DocumentCaption,CopyText); DataSetFieldName=STRSUBSTNO_DocumentCaption_CopyText_ } { 2 ;TextBox ;11550;423 ;1680 ;423 ;FontSize=9; SourceExpr=STRSUBSTNO(Text005,FORMAT(CurrReport.PAGENO)); DataSetFieldName=STRSUBSTNO_Text005_FORMAT_CurrReport_PAGENO__ } { 4 ;TextBox ;0 ;1269 ;6300 ;423 ;FontSize=9; SourceExpr=CustAddr[1]; DataSetFieldName=CustAddr_1_ } { 5 ;TextBox ;11550;1269 ;6300 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=CompanyAddr[1]; DataSetFieldName=CompanyAddr_1_ } { 6 ;TextBox ;0 ;1692 ;6300 ;423 ;FontSize=9; SourceExpr=CustAddr[2]; DataSetFieldName=CustAddr_2_ } { 7 ;TextBox ;11550;1692 ;6300 ;423 ;FontSize=9; SourceExpr=CompanyAddr[2]; DataSetFieldName=CompanyAddr_2_ } { 8 ;TextBox ;0 ;2115 ;6300 ;423 ;FontSize=9; SourceExpr=CustAddr[3]; DataSetFieldName=CustAddr_3_ } { 9 ;TextBox ;11550;2115 ;6300 ;423 ;FontSize=9; SourceExpr=CompanyAddr[3]; DataSetFieldName=CompanyAddr_3_ } { 10 ;TextBox ;0 ;2538 ;6300 ;423 ;FontSize=9; SourceExpr=CustAddr[4]; DataSetFieldName=CustAddr_4_ } { 11 ;TextBox ;11550;2538 ;6300 ;423 ;FontSize=9; SourceExpr=CompanyAddr[4]; DataSetFieldName=CompanyAddr_4_ } { 12 ;TextBox ;0 ;2961 ;6300 ;423 ;FontSize=9; SourceExpr=CustAddr[5]; DataSetFieldName=CustAddr_5_ } { 13 ;Label ;11550;3807 ;2100 ;423 ;ParentControl=14; FontSize=9; DataSetFieldName=CompanyInfo__Phone_No__Caption } { 14 ;TextBox ;13860;3807 ;4200 ;423 ;FontSize=9; CaptionML=[ENU=Phone No.; FRB=Nø t‚l‚phone; NLB=Telefoon]; SourceExpr=CompanyInfo."Phone No."; DataSetFieldName=CompanyInfo__Phone_No__ } { 15 ;TextBox ;0 ;3384 ;6300 ;423 ;FontSize=9; SourceExpr=CustAddr[6]; DataSetFieldName=CustAddr_6_ } { 16 ;Label ;11550;4230 ;2100 ;423 ;ParentControl=17; FontSize=9; DataSetFieldName=CompanyInfo__Fax_No__Caption } { 17 ;TextBox ;13860;4230 ;4200 ;423 ;FontSize=9; CaptionML=[ENU=Fax No.; FRB=Nø t‚l‚copie; NLB=Fax]; SourceExpr=CompanyInfo."Fax No."; DataSetFieldName=CompanyInfo__Fax_No__ } { 20 ;Label ;11550;5076 ;2100 ;423 ;ParentControl=21; FontSize=9; DataSetFieldName=CompanyInfo__Giro_No__Caption } { 21 ;TextBox ;13860;5076 ;4200 ;423 ;FontSize=9; CaptionML=[ENU=Giro No.; FRB=Nø CCP; NLB=Gironr.]; SourceExpr=CompanyInfo."Giro No."; DataSetFieldName=CompanyInfo__Giro_No__ } { 22 ;Label ;11550;5499 ;2100 ;423 ;ParentControl=23; FontSize=9; DataSetFieldName=CompanyInfo__Bank_Name_Caption } { 23 ;TextBox ;13860;5499 ;4200 ;423 ;FontSize=9; CaptionML=[ENU=Bank; FRB=Banque; NLB=Bank]; SourceExpr=CompanyInfo."Bank Name"; DataSetFieldName=CompanyInfo__Bank_Name_ } { 24 ;Label ;11550;5922 ;2100 ;423 ;ParentControl=25; FontSize=9; DataSetFieldName=CompanyInfo__Bank_Account_No__Caption } { 25 ;TextBox ;13860;5922 ;4200 ;423 ;FontSize=9; CaptionML=[ENU=Account No.; FRB=Nø compte; NLB=Rekeningnr.]; SourceExpr=CompanyInfo."Bank Account No."; DataSetFieldName=CompanyInfo__Bank_Account_No__ } { 26 ;Label ;0 ;6768 ;3150 ;423 ;ParentControl=27; FontSize=9; DataSetFieldName=Sales_Invoice_Header___Bill_to_Customer_No__Caption } { 27 ;TextBox ;3360 ;6768 ;2100 ;423 ;HorzAlign=Left; FontSize=9; SourceExpr="Sales Invoice Header"."Bill-to Customer No."; DataSetFieldName=Sales_Invoice_Header___Bill_to_Customer_No__ } { 28 ;TextBox ;14910;8460 ;2100 ;423 ;HorzAlign=Left; FontSize=9; CaptionML=[ENU=Posting Date; FRB=Date comptabilisation; NLB=Boekingsdatum]; SourceExpr=FORMAT("Sales Invoice Header"."Posting Date"); DataSetFieldName=Sales_Invoice_Header___Posting_Date_ } { 29 ;TextBox ;0 ;7614 ;3150 ;423 ;FontSize=9; SourceExpr=VATNoText; DataSetFieldName=VATNoText } { 30 ;TextBox ;3360 ;7614 ;4200 ;423 ;FontSize=9; SourceExpr=NoText; DataSetFieldName=NoText } { 31 ;Label ;11550;8883 ;3150 ;423 ;ParentControl=32; FontSize=9; DataSetFieldName=Sales_Invoice_Header___Due_Date_Caption } { 32 ;TextBox ;14910;8883 ;2100 ;423 ;HorzAlign=Left; FontSize=9; CaptionML=[ENU=Due Date; FRB=Date d'‚ch‚ance; NLB=Vervaldatum]; SourceExpr=FORMAT("Sales Invoice Header"."Due Date"); DataSetFieldName=Sales_Invoice_Header___Due_Date_ } { 33 ;TextBox ;0 ;8037 ;3150 ;423 ;FontSize=9; SourceExpr=SalesPersonText; DataSetFieldName=SalesPersonText } { 34 ;TextBox ;3360 ;8037 ;6300 ;423 ;FontSize=9; SourceExpr=SalesPurchPerson.Name; DataSetFieldName=SalesPurchPerson_Name } { 35 ;Label ;11550;7614 ;2100 ;423 ;FontSize=9; CaptionML=[ENU=Invoice No.; FRB=Nø facture; NLB=Factuurnr.]; DataSetFieldName=Invoice_No_Caption } { 36 ;TextBox ;14910;7614 ;2100 ;423 ;HorzAlign=Left; FontSize=9; SourceExpr="Sales Invoice Header"."No."; DataSetFieldName=Sales_Invoice_Header___No__ } { 37 ;TextBox ;0 ;8460 ;3150 ;423 ;FontSize=9; SourceExpr=ReferenceText; DataSetFieldName=ReferenceText } { 38 ;TextBox ;3360 ;8460 ;6300 ;423 ;FontSize=9; SourceExpr="Sales Invoice Header"."Your Reference"; DataSetFieldName=Sales_Invoice_Header___Your_Reference_ } { 39 ;TextBox ;11550;8037 ;2100 ;423 ;FontSize=9; SourceExpr=OrderNoText; DataSetFieldName=OrderNoText } { 40 ;TextBox ;14910;8037 ;2100 ;423 ;HorzAlign=Left; FontSize=9; SourceExpr="Sales Invoice Header"."Order No."; DataSetFieldName=Sales_Invoice_Header___Order_No__ } { 3 ;TextBox ;0 ;3807 ;6300 ;423 ;FontSize=9; SourceExpr=CustAddr[7]; DataSetFieldName=CustAddr_7_ } { 48 ;TextBox ;0 ;4230 ;6300 ;423 ;FontSize=9; SourceExpr=CustAddr[8]; DataSetFieldName=CustAddr_8_ } { 49 ;TextBox ;11550;2961 ;6300 ;423 ;FontSize=9; SourceExpr=CompanyAddr[5]; DataSetFieldName=CompanyAddr_5_ } { 50 ;TextBox ;11550;3384 ;6300 ;423 ;FontSize=9; SourceExpr=CompanyAddr[6]; DataSetFieldName=CompanyAddr_6_ } { 53 ;Label ;11550;8460 ;3150 ;423 ;ParentControl=28; FontSize=9; DataSetFieldName=Sales_Invoice_Header___Posting_Date_Caption } { 54 ;TextBox ;11550;6768 ;4410 ;423 ;FontSize=9; SourceExpr=FORMAT("Sales Invoice Header"."Document Date",0,4); DataSetFieldName=FORMAT__Sales_Invoice_Header___Document_Date__0_4_ } { 58 ;TextBox ;14910;9306 ;1680 ;423 ;HorzAlign=Left; FontSize=9; SourceExpr="Sales Invoice Header"."Prices Including VAT"; DataSetFieldName=Sales_Invoice_Header___Prices_Including_VAT_ } { 59 ;Label ;11550;9306 ;3150 ;423 ;ParentControl=58; FontSize=9; DataSetFieldName=Sales_Invoice_Header___Prices_Including_VAT_Caption } { 154 ;TextBox ;13440;423 ;150 ;423 ;Name=OutputNo; Visible=No; ForeColor=65535; SourceExpr=OutputNo; DataSetFieldName=OutputNo } { 159 ;TextBox ;16590;9306 ;150 ;423 ;Name=PricesInclVAT_YesNo; Visible=No; ForeColor=65535; SourceExpr=FORMAT("Sales Invoice Header"."Prices Including VAT"); DataSetFieldName=PricesInclVAT_YesNo } { 160 ;TextBox ;13230;423 ;150 ;423 ;Name=PageCaption; Visible=No; ForeColor=65535; SourceExpr=STRSUBSTNO(Text005,''); DataSetFieldName=PageCaption } { 1010000;Label ;11550;4653 ;2100 ;423 ;ParentControl=1010001; FontSize=9; DataSetFieldName=CompanyInfo__Enterprise_No__Caption } { 1010001;TextBox ;13860;4653 ;4200 ;423 ;FontSize=9; CaptionML=[ENU=Enterprise No.; FRB=Nø de soci‚t‚; NLB=Ondernemingsnr.]; SourceExpr=CompanyInfo."Enterprise No."; DataSetFieldName=CompanyInfo__Enterprise_No__ } } } } } { PROPERTIES { DataItemIndent=3; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number) WHERE(Number=FILTER(1..)); DataItemVarName=DimensionLoop1; OnPreDataItem=BEGIN IF NOT ShowInternalInfo THEN CurrReport.BREAK; END; OnAfterGetRecord=BEGIN IF Number = 1 THEN BEGIN IF NOT PostedDocDim1.FIND('-') THEN CurrReport.BREAK; END ELSE IF NOT Continue THEN CurrReport.BREAK; CLEAR(DimText); Continue := FALSE; REPEAT OldDimText := DimText; IF DimText = '' THEN DimText := STRSUBSTNO( '%1 %2',PostedDocDim1."Dimension Code",PostedDocDim1."Dimension Value Code") ELSE DimText := STRSUBSTNO( '%1, %2 %3',DimText, PostedDocDim1."Dimension Code",PostedDocDim1."Dimension Value Code"); IF STRLEN(DimText) > MAXSTRLEN(OldDimText) THEN BEGIN DimText := OldDimText; Continue := TRUE; EXIT; END; UNTIL (PostedDocDim1.NEXT = 0); END; DataItemLinkReference=Sales Invoice Header; } SECTIONS { { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; OnPreSection=BEGIN CurrReport.SHOWOUTPUT(Number = 1); END; } CONTROLS { { 91 ;TextBox ;3360 ;0 ;14700;423 ;FontSize=9; SourceExpr=DimText; DataSetFieldName=DimText } { 93 ;Label ;0 ;0 ;3150 ;423 ;FontSize=9; CaptionML=[ENU=Header Dimensions; FRB=Analytique en-tˆte; NLB=Kopdimensies]; DataSetFieldName=Header_DimensionsCaption } { 161 ;TextBox ;3150 ;0 ;150 ;423 ;Name=DimensionLoop1.Number; Visible=No; ForeColor=65535; SourceExpr=DimensionLoop1.Number; DataSetFieldName=DimensionLoop1_Number } } } { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; OnPreSection=BEGIN CurrReport.SHOWOUTPUT(Number > 1); END; } CONTROLS { { 98 ;TextBox ;3360 ;0 ;14700;423 ;FontSize=9; SourceExpr=DimText; DataSetFieldName=DimText_Control98 } } } } } { PROPERTIES { DataItemIndent=3; DataItemTable=Table113; DataItemTableView=SORTING(Document No.,Line No.); OnPreDataItem=BEGIN VATAmountLine.DELETEALL; SalesShipmentBuffer.RESET; SalesShipmentBuffer.DELETEALL; FirstValueEntryNo := 0; MoreLines := FIND('+'); WHILE MoreLines AND (Description = '') AND ("No." = '') AND (Quantity = 0) AND (Amount = 0) DO MoreLines := NEXT(-1) <> 0; IF NOT MoreLines THEN CurrReport.BREAK; SETRANGE("Line No.",0,"Line No."); CurrReport.CREATETOTALS("Line Amount",Amount,"Amount Including VAT","Inv. Discount Amount"); END; OnAfterGetRecord=BEGIN PostedShipmentDate := 0D; IF Quantity <> 0 THEN PostedShipmentDate := FindPostedShipmentDate; IF (Type = Type::"G/L Account") AND (NOT ShowInternalInfo) THEN "No." := ''; VATAmountLine.INIT; VATAmountLine."VAT Identifier" := "VAT Identifier"; VATAmountLine."VAT Calculation Type" := "VAT Calculation Type"; VATAmountLine."Tax Group Code" := "Tax Group Code"; VATAmountLine."VAT %" := "VAT %"; VATAmountLine."VAT Base" := Amount; VATAmountLine."Amount Including VAT" := "Amount Including VAT"; VATAmountLine."Line Amount" := "Line Amount"; IF "Allow Invoice Disc." THEN VATAmountLine."Inv. Disc. Base Amount" := "Line Amount"; VATAmountLine."Invoice Discount Amount" := "Inv. Discount Amount"; VATAmountLine."VAT Base (Lowered)" := "VAT Base Amount"; VATAmountLine.InsertLine; IF ISSERVICETIER THEN BEGIN TotalSubTotal += "Line Amount"; TotalInvoiceDiscountAmount -= "Inv. Discount Amount"; TotalAmount += Amount; TotalAmountVAT += "Amount Including VAT" - Amount; TotalAmountInclVAT += "Amount Including VAT"; TotalPaymentDiscountOnVAT += -("Line Amount" - "Inv. Discount Amount" - "Amount Including VAT"); END END; DataItemLinkReference=Sales Invoice Header; DataItemLink=Document No.=FIELD(No.); } SECTIONS { { PROPERTIES { SectionType=Header; PrintOnEveryPage=Yes; SectionWidth=18060; SectionHeight=1692; } CONTROLS { { 41 ;Label ;0 ;423 ;2100 ;846 ;ParentControl=64; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=Sales_Invoice_Line__No__Caption } { 42 ;Label ;2310 ;423 ;4410 ;846 ;ParentControl=65; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=Sales_Invoice_Line_Description_Control65Caption } { 43 ;Label ;8610 ;423 ;1470 ;846 ;ParentControl=66; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=Sales_Invoice_Line_QuantityCaption } { 44 ;Label ;10290;423 ;1470 ;846 ;ParentControl=67; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=Sales_Invoice_Line__Unit_of_Measure_Caption } { 45 ;Label ;11760;423 ;1680 ;846 ;ParentControl=68; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; CaptionML=[ENU=Unit Price; FRB=Prix unitaire; NLB=Eenheidsprijs]; DataSetFieldName=Unit_PriceCaption } { 46 ;Label ;13440;423 ;840 ;846 ;ParentControl=69; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=Sales_Invoice_Line__Line_Discount___Caption } { 47 ;Label ;15960;423 ;2100 ;846 ;ParentControl=70; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; CaptionML=[ENU=Amount; FRB=Montant; NLB=Bedrag]; DataSetFieldName=AmountCaption } { 102 ;Label ;14490;423 ;1470 ;846 ;ParentControl=101; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=Sales_Invoice_Line__VAT_Identifier_Caption } { 106 ;Label ;6930 ;0 ;1470 ;1269 ;ParentControl=100; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=PostedShipmentDateCaption } } } { PROPERTIES { SectionType=TransHeader; SectionWidth=18060; SectionHeight=846; } CONTROLS { { 55 ;Label ;11130;0 ;4200 ;423 ;ParentControl=56; FontSize=9; LeaderDots=Yes; CaptionML=[ENU=Continued; FRB=Report; NLB=Transport]; DataSetFieldName=ContinuedCaption } { 56 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Continued; FRB=Report; NLB=Transport]; SourceExpr="Line Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line__Line_Amount_ } } } { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; OnPreSection=BEGIN CurrReport.SHOWOUTPUT(Type = 0); END; } CONTROLS { { 57 ;TextBox ;2310 ;0 ;10500;423 ;FontSize=9; SourceExpr=Description; DataSetFieldName=Sales_Invoice_Line_Description } } } { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; OnPreSection=BEGIN CurrReport.SHOWOUTPUT(Type > 0); END; } CONTROLS { { 64 ;TextBox ;0 ;0 ;2100 ;423 ;HorzAlign=Left; FontSize=9; SourceExpr="No."; DataSetFieldName=Sales_Invoice_Line__No__ } { 65 ;TextBox ;2310 ;0 ;4410 ;423 ;FontSize=9; SourceExpr=Description; DataSetFieldName=Sales_Invoice_Line_Description_Control65 } { 66 ;TextBox ;8610 ;0 ;1470 ;423 ;FontSize=9; BlankZero=Yes; SourceExpr=Quantity; DataSetFieldName=Sales_Invoice_Line_Quantity } { 67 ;TextBox ;10290;0 ;1470 ;423 ;FontSize=9; SourceExpr="Unit of Measure"; DataSetFieldName=Sales_Invoice_Line__Unit_of_Measure_ } { 68 ;TextBox ;11760;0 ;1680 ;423 ;FontSize=9; BlankZero=Yes; SourceExpr="Unit Price"; AutoFormatType=2; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line__Unit_Price_ } { 69 ;TextBox ;13440;0 ;840 ;423 ;FontSize=9; CaptionML=[ENU=Disc. %; FRB=% remise; NLB=K. %]; BlankZero=Yes; SourceExpr="Line Discount %"; DataSetFieldName=Sales_Invoice_Line__Line_Discount___ } { 70 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Amount; FRB=Montant; NLB=Bedrag]; BlankZero=Yes; SourceExpr="Line Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line__Line_Amount__Control70 } { 101 ;TextBox ;14490;0 ;1050 ;423 ;FontSize=9; SourceExpr="VAT Identifier"; DataSetFieldName=Sales_Invoice_Line__VAT_Identifier_ } { 100 ;TextBox ;6930 ;0 ;1470 ;423 ;FontSize=9; CaptionML=[ENU=Posted Shipment Date; FRB=Date exp‚dition valid‚e; NLB=Datum geboekte verzending]; SourceExpr=FORMAT(PostedShipmentDate); DataSetFieldName=PostedShipmentDate } { 155 ;TextBox ;17850;0 ;150 ;423 ;Name=SalesLineType; Visible=No; ForeColor=65535; SourceExpr=FORMAT("Sales Invoice Line".Type); DataSetFieldName=SalesLineType } } } { PROPERTIES { SectionType=TransFooter; SectionWidth=18060; SectionHeight=846; } CONTROLS { { 85 ;Label ;11130;423 ;4200 ;423 ;ParentControl=86; FontSize=9; LeaderDots=Yes; CaptionML=[ENU=Continued; FRB=Report; NLB=Transport]; DataSetFieldName=ContinuedCaption_Control85 } { 86 ;TextBox ;15540;423 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Continued; FRB=Report; NLB=Transport]; SourceExpr="Line Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line__Line_Amount__Control86 } } } { PROPERTIES { SectionType=Footer; SectionWidth=18060; SectionHeight=423; } CONTROLS { } } { PROPERTIES { SectionType=Footer; SectionWidth=18060; SectionHeight=846; OnPreSection=BEGIN CurrReport.SHOWOUTPUT("Inv. Discount Amount" <> 0); END; } CONTROLS { { 87 ;Label ;11130;423 ;4200 ;423 ;ParentControl=88; FontSize=9; DataSetFieldName=Inv__Discount_Amount_Caption } { 88 ;TextBox ;15540;423 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Inv. Discount Amount; FRB=Montant remise facture; NLB=Factuurkorting]; SourceExpr=-"Inv. Discount Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Inv__Discount_Amount_ } { 89 ;Label ;11130;0 ;4200 ;423 ;ParentControl=99; FontSize=9; FontBold=Yes; CaptionML=[ENU=Subtotal; FRB=Sous-total; NLB=Subtotaal]; DataSetFieldName=SubtotalCaption } { 99 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; FontBold=Yes; CaptionML=[ENU=Subtotal; FRB=Sous-total; NLB=Subtotaal]; SourceExpr="Line Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=Sales_Invoice_Line__Line_Amount__Control99 } { 166 ;TextBox ;10920;0 ;150 ;423 ;Visible=No; ForeColor=65535; FontSize=9; SourceExpr=TotalSubTotal; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=TotalSubTotal } { 172 ;TextBox ;10920;423 ;150 ;423 ;Visible=No; ForeColor=65535; FontSize=9; SourceExpr=TotalInvoiceDiscountAmount; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=TotalInvoiceDiscountAmount } } } { PROPERTIES { SectionType=Footer; SectionWidth=18060; SectionHeight=846; OnPreSection=BEGIN CurrReport.SHOWOUTPUT("Amount Including VAT" = Amount); END; } CONTROLS { { 73 ;TextBox ;11130;0 ;4200 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=TotalText; DataSetFieldName=TotalText } { 74 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=Amount; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line_Amount } { 167 ;TextBox ;10920;0 ;150 ;423 ;Visible=No; ForeColor=65535; FontSize=9; SourceExpr=TotalAmount; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=TotalAmount } } } { PROPERTIES { SectionType=Footer; SectionWidth=18060; SectionHeight=1692; OnPreSection=BEGIN CurrReport.SHOWOUTPUT( (NOT "Sales Invoice Header"."Prices Including VAT") AND ("Amount Including VAT" <> Amount)); END; } CONTROLS { { 90 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=Amount; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line_Amount_Control90 } { 92 ;TextBox ;15540;423 ;2520 ;423 ;FontSize=9; SourceExpr="Amount Including VAT" - Amount; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Amount_Including_VAT____Amount } { 94 ;TextBox ;15540;846 ;2520 ;423 ;FontSize=9; FontBold=Yes; SourceExpr="Amount Including VAT"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line__Amount_Including_VAT_ } { 79 ;TextBox ;11130;423 ;4200 ;423 ;FontSize=9; SourceExpr=VATAmountLine.VATAmountText; DataSetFieldName=VATAmountLine_VATAmountText } { 80 ;TextBox ;11130;0 ;4200 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=TotalExclVATText; DataSetFieldName=TotalExclVATText } { 81 ;TextBox ;11130;846 ;4200 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=TotalInclVATText; DataSetFieldName=TotalInclVATText } { 174 ;TextBox ;10920;846 ;150 ;423 ;Visible=No; ForeColor=65535; FontSize=9; SourceExpr=TotalAmountInclVAT; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=TotalAmountInclVAT } { 168 ;TextBox ;10920;423 ;150 ;423 ;Visible=No; ForeColor=65535; FontSize=9; SourceExpr=TotalAmountVAT; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=TotalAmountVAT } } } { PROPERTIES { SectionType=Footer; SectionWidth=18060; SectionHeight=423; OnPreSection=BEGIN CurrReport.SHOWOUTPUT( "Sales Invoice Header"."Prices Including VAT" AND ("Amount Including VAT" <> Amount) AND ("Sales Invoice Header"."VAT Base Discount %" <> 0)); END; } CONTROLS { { 84 ;Label ;11130;0 ;4200 ;423 ;ParentControl=143; FontSize=9; DataSetFieldName=Line_Amount_____Inv__Discount_Amount_____Amount_Including_VAT__Caption } { 143 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Payment Discount on VAT; FRB=Escompte sur TVA; NLB=Contantkorting op btw]; SourceExpr=-("Line Amount" - "Inv. Discount Amount" - "Amount Including VAT"); AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=Line_Amount_____Inv__Discount_Amount_____Amount_Including_VAT__ } { 173 ;TextBox ;10920;0 ;150 ;423 ;Visible=No; ForeColor=65535; FontSize=9; SourceExpr="Sales Invoice Header"."VAT Base Discount %"; AutoFormatType=1; DataSetFieldName=Sales_Invoice_Header___VAT_Base_Discount___ } { 177 ;TextBox ;10710;0 ;150 ;423 ;Visible=No; ForeColor=65535; FontSize=9; SourceExpr=TotalPaymentDiscountOnVAT; AutoFormatType=1; DataSetFieldName=TotalPaymentDiscountOnVAT } } } { PROPERTIES { SectionType=Footer; SectionWidth=18060; SectionHeight=2115; OnPreSection=BEGIN CurrReport.SHOWOUTPUT( "Sales Invoice Header"."Prices Including VAT" AND ("Amount Including VAT" <> Amount)); END; } CONTROLS { { 60 ;TextBox ;11130;0 ;4200 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=TotalInclVATText; DataSetFieldName=TotalInclVATText_Control60 } { 61 ;TextBox ;11130;846 ;4200 ;423 ;FontSize=9; SourceExpr=VATAmountLine.VATAmountText; DataSetFieldName=VATAmountLine_VATAmountText_Control61 } { 62 ;TextBox ;15540;846 ;2520 ;423 ;FontSize=9; SourceExpr="Amount Including VAT" - Amount; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Amount_Including_VAT____Amount_Control62 } { 63 ;TextBox ;15540;1269 ;2520 ;423 ;FontSize=9; SourceExpr=Amount; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line_Amount_Control63 } { 71 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; FontBold=Yes; SourceExpr="Amount Including VAT"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=Sales_Invoice_Line__Amount_Including_VAT__Control71 } { 72 ;TextBox ;11130;1269 ;4200 ;423 ;FontSize=9; SourceExpr=TotalExclVATText; DataSetFieldName=TotalExclVATText_Control72 } } } } } { PROPERTIES { DataItemIndent=4; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number); DataItemVarName=Sales Shipment Buffer; OnPreDataItem=BEGIN SalesShipmentBuffer.SETRANGE("Document No.","Sales Invoice Line"."Document No."); SalesShipmentBuffer.SETRANGE("Line No.","Sales Invoice Line"."Line No."); SETRANGE(Number,1,SalesShipmentBuffer.COUNT); END; OnAfterGetRecord=BEGIN IF Number = 1 THEN SalesShipmentBuffer.FIND('-') ELSE SalesShipmentBuffer.NEXT; END; } SECTIONS { { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; } CONTROLS { { 144 ;TextBox ;6930 ;0 ;1470 ;423 ;FontSize=9; SourceExpr=FORMAT(SalesShipmentBuffer."Posting Date"); DataSetFieldName=SalesShipmentBuffer__Posting_Date_ } { 146 ;TextBox ;8610 ;0 ;1470 ;423 ;FontSize=9; DecimalPlaces=0:5; SourceExpr=SalesShipmentBuffer.Quantity; DataSetFieldName=SalesShipmentBuffer_Quantity } { 145 ;Label ;2310 ;0 ;4410 ;423 ;VertAlign=Bottom; FontSize=9; FontBold=No; MultiLine=Yes; CaptionML=[ENU=Shipment; FRB=Exp‚dition; NLB=Verzending]; DataSetFieldName=ShipmentCaption } } } } } { PROPERTIES { DataItemIndent=4; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number) WHERE(Number=FILTER(1..)); DataItemVarName=DimensionLoop2; OnPreDataItem=BEGIN IF NOT ShowInternalInfo THEN CurrReport.BREAK; PostedDocDim2.SETRANGE("Table ID",DATABASE::"Sales Invoice Line"); PostedDocDim2.SETRANGE("Document No.","Sales Invoice Line"."Document No."); PostedDocDim2.SETRANGE("Line No.","Sales Invoice Line"."Line No."); END; OnAfterGetRecord=BEGIN IF Number = 1 THEN BEGIN IF NOT PostedDocDim2.FIND('-') THEN CurrReport.BREAK; END ELSE IF NOT Continue THEN CurrReport.BREAK; CLEAR(DimText); Continue := FALSE; REPEAT OldDimText := DimText; IF DimText = '' THEN DimText := STRSUBSTNO( '%1 %2',PostedDocDim2."Dimension Code",PostedDocDim2."Dimension Value Code") ELSE DimText := STRSUBSTNO( '%1, %2 %3',DimText, PostedDocDim2."Dimension Code",PostedDocDim2."Dimension Value Code"); IF STRLEN(DimText) > MAXSTRLEN(OldDimText) THEN BEGIN DimText := OldDimText; Continue := TRUE; EXIT; END; UNTIL (PostedDocDim2.NEXT = 0); END; } SECTIONS { { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; } CONTROLS { { 82 ;TextBox ;3360 ;0 ;14700;423 ;FontSize=9; SourceExpr=DimText; DataSetFieldName=DimText_Control82 } { 83 ;Label ;0 ;0 ;3150 ;423 ;FontSize=9; CaptionML=[ENU=Line Dimensions; FRB=Analytique ligne; NLB=Regeldimensies]; DataSetFieldName=Line_DimensionsCaption } } } } } { PROPERTIES { DataItemIndent=3; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number); DataItemVarName=VATCounter; OnPreDataItem=BEGIN IF VATAmountLine.GetTotalVATAmount = 0 THEN CurrReport.BREAK; SETRANGE(Number,1,VATAmountLine.COUNT); CurrReport.CREATETOTALS( VATAmountLine."Line Amount",VATAmountLine."Inv. Disc. Base Amount", VATAmountLine."Invoice Discount Amount",VATAmountLine."VAT Base (Lowered)",VATAmountLine."VAT Amount"); END; OnAfterGetRecord=BEGIN VATAmountLine.GetLine(Number); END; } SECTIONS { { PROPERTIES { SectionType=Header; PrintOnEveryPage=Yes; SectionWidth=18060; SectionHeight=2115; } CONTROLS { { 95 ;Label ;2310 ;846 ;2100 ;846 ;ParentControl=107; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__VAT___Caption } { 96 ;Label ;12810;846 ;2520 ;846 ;ParentControl=108; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__VAT_Base__Control108Caption } { 97 ;Label ;15540;846 ;2520 ;846 ;ParentControl=109; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__VAT_Amount__Control109Caption } { 78 ;Label ;0 ;0 ;6300 ;423 ;FontSize=9; FontBold=Yes; CaptionML=[ENU=VAT Amount Specification; FRB=D‚tail TVA; NLB=Specificatie btw-bedrag]; DataSetFieldName=VAT_Amount_SpecificationCaption } { 136 ;Label ;0 ;846 ;2100 ;846 ;ParentControl=135; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__VAT_Identifier_Caption } { 137 ;Label ;7350 ;423 ;2520 ;1269 ;ParentControl=141; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__Inv__Disc__Base_Amount__Control141Caption } { 138 ;Label ;4620 ;846 ;2520 ;846 ;ParentControl=140; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__Line_Amount__Control140Caption } { 139 ;Label ;10080;423 ;2520 ;1269 ;ParentControl=142; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__Invoice_Discount_Amount__Control142Caption } } } { PROPERTIES { SectionType=TransHeader; SectionWidth=18060; SectionHeight=846; } CONTROLS { { 103 ;Label ;0 ;0 ;2100 ;423 ;ParentControl=104; FontSize=9; LeaderDots=Yes; DataSetFieldName=VATAmountLine__VAT_Base_Caption } { 104 ;TextBox ;12810;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Continued; FRB=Report; NLB=Transport]; SourceExpr=VATAmountLine."VAT Base (Lowered)"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Line".GetCurrencyCode; DataSetFieldName=VATAmountLine__VAT_Base_ } { 105 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; SourceExpr=VATAmountLine."VAT Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__VAT_Amount_ } { 75 ;TextBox ;4620 ;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Line Amount; FRB=Montant ligne; NLB=Regelbedrag]; SourceExpr=VATAmountLine."Line Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Line_Amount_ } { 76 ;TextBox ;7350 ;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Inv. Disc. Base Amount; FRB=Montant base remise facture; NLB=Basisbedrag factuurkorting]; SourceExpr=VATAmountLine."Inv. Disc. Base Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Inv__Disc__Base_Amount_ } { 77 ;TextBox ;10080;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Invoice Discount Amount; FRB=Montant remise facture; NLB=Bedrag factuurkorting]; SourceExpr=VATAmountLine."Invoice Discount Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Invoice_Discount_Amount_ } } } { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; } CONTROLS { { 107 ;TextBox ;2310 ;0 ;2100 ;423 ;FontSize=9; CaptionML=[ENU=VAT %; FRB=% TVA; NLB=Btw %]; DecimalPlaces=0:5; SourceExpr=VATAmountLine."VAT %"; DataSetFieldName=VATAmountLine__VAT___ } { 108 ;TextBox ;12810;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=VAT Base; FRB=Base TVA; NLB=Basisbedrag btw]; SourceExpr=VATAmountLine."VAT Base (Lowered)"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__VAT_Base__Control108 } { 109 ;TextBox ;15540;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=VAT Amount; FRB=Montant TVA; NLB=Btw-bedrag]; SourceExpr=VATAmountLine."VAT Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__VAT_Amount__Control109 } { 135 ;TextBox ;0 ;0 ;2100 ;423 ;FontSize=9; CaptionML=[ENU=VAT Identifier; FRB=Identifiant TVA; NLB=Btw-identificatie]; SourceExpr=VATAmountLine."VAT Identifier"; DataSetFieldName=VATAmountLine__VAT_Identifier_ } { 140 ;TextBox ;4620 ;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Line Amount; FRB=Montant ligne; NLB=Regelbedrag]; SourceExpr=VATAmountLine."Line Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Line_Amount__Control140 } { 141 ;TextBox ;7350 ;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Inv. Disc. Base Amount; FRB=Montant base remise facture; NLB=Basisbedrag factuurkorting]; SourceExpr=VATAmountLine."Inv. Disc. Base Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Inv__Disc__Base_Amount__Control141 } { 142 ;TextBox ;10080;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Invoice Discount Amount; FRB=Montant remise facture; NLB=Bedrag factuurkorting]; SourceExpr=VATAmountLine."Invoice Discount Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Invoice_Discount_Amount__Control142 } } } { PROPERTIES { SectionType=TransFooter; SectionWidth=18060; SectionHeight=846; } CONTROLS { { 111 ;Label ;0 ;423 ;2100 ;423 ;ParentControl=112; FontSize=9; LeaderDots=Yes; DataSetFieldName=VATAmountLine__VAT_Base__Control112Caption } { 112 ;TextBox ;12810;423 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Continued; FRB=Report; NLB=Transport]; SourceExpr=VATAmountLine."VAT Base (Lowered)"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__VAT_Base__Control112 } { 113 ;TextBox ;15540;423 ;2520 ;423 ;FontSize=9; SourceExpr=VATAmountLine."VAT Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__VAT_Amount__Control113 } { 110 ;TextBox ;4620 ;423 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Line Amount; FRB=Montant ligne; NLB=Regelbedrag]; SourceExpr=VATAmountLine."Line Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Line_Amount__Control110 } { 114 ;TextBox ;7350 ;423 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Inv. Disc. Base Amount; FRB=Montant base remise facture; NLB=Basisbedrag factuurkorting]; SourceExpr=VATAmountLine."Inv. Disc. Base Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Inv__Disc__Base_Amount__Control114 } { 118 ;TextBox ;10080;423 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Invoice Discount Amount; FRB=Montant remise facture; NLB=Bedrag factuurkorting]; SourceExpr=VATAmountLine."Invoice Discount Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Invoice_Discount_Amount__Control118 } } } { PROPERTIES { SectionType=Footer; SectionWidth=18060; SectionHeight=846; } CONTROLS { { 115 ;Label ;0 ;423 ;2100 ;423 ;ParentControl=116; FontSize=9; FontBold=Yes; DataSetFieldName=VATAmountLine__VAT_Base__Control116Caption } { 116 ;TextBox ;12810;423 ;2520 ;423 ;FontSize=9; FontBold=Yes; CaptionML=[ENU=Total; FRB=Total; NLB=Totaal]; SourceExpr=VATAmountLine."VAT Base (Lowered)"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__VAT_Base__Control116 } { 117 ;TextBox ;15540;423 ;2520 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=VATAmountLine."VAT Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__VAT_Amount__Control117 } { 132 ;TextBox ;4620 ;423 ;2520 ;423 ;FontSize=9; FontBold=Yes; CaptionML=[ENU=Line Amount; FRB=Montant ligne; NLB=Regelbedrag]; SourceExpr=VATAmountLine."Line Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Line_Amount__Control132 } { 133 ;TextBox ;7350 ;423 ;2520 ;423 ;FontSize=9; FontBold=Yes; CaptionML=[ENU=Inv. Disc. Base Amount; FRB=Montant base remise facture; NLB=Basisbedrag factuurkorting]; SourceExpr=VATAmountLine."Inv. Disc. Base Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Inv__Disc__Base_Amount__Control133 } { 134 ;TextBox ;10080;423 ;2520 ;423 ;FontSize=9; FontBold=Yes; CaptionML=[ENU=Invoice Discount Amount; FRB=Montant remise facture; NLB=Bedrag factuurkorting]; SourceExpr=VATAmountLine."Invoice Discount Amount"; AutoFormatType=1; AutoFormatExpr="Sales Invoice Header"."Currency Code"; DataSetFieldName=VATAmountLine__Invoice_Discount_Amount__Control134 } } } } } { PROPERTIES { DataItemIndent=3; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number); DataItemVarName=VatCounterLCY; OnPreDataItem=BEGIN IF (NOT GLSetup."Print VAT specification in LCY") OR ("Sales Invoice Header"."Currency Code" = '') OR (VATAmountLine.GetTotalVATAmount = 0) THEN CurrReport.BREAK; SETRANGE(Number,1,VATAmountLine.COUNT); CurrReport.CREATETOTALS(VALVATBaseLCY,VALVATAmountLCY); IF GLSetup."LCY Code" = '' THEN VALSpecLCYHeader := Text007 + Text008 ELSE VALSpecLCYHeader := Text007 + FORMAT(GLSetup."LCY Code"); CurrExchRate.FindCurrency("Sales Invoice Header"."Posting Date","Sales Invoice Header"."Currency Code",1); CalculatedExchRate := ROUND(1 / "Sales Invoice Header"."Currency Factor" * CurrExchRate."Exchange Rate Amount",0.000001); VALExchRate := STRSUBSTNO(Text009,CalculatedExchRate,CurrExchRate."Exchange Rate Amount"); END; OnAfterGetRecord=BEGIN VATAmountLine.GetLine(Number); VALVATBaseLCY := ROUND(VATAmountLine."VAT Base" / "Sales Invoice Header"."Currency Factor"); VALVATAmountLCY :=ROUND(VATAmountLine."VAT Amount" / "Sales Invoice Header"."Currency Factor"); END; } SECTIONS { { PROPERTIES { SectionType=Header; PrintOnEveryPage=Yes; SectionWidth=18060; SectionHeight=2538; } CONTROLS { { 150 ;Label ;2310 ;1692 ;2100 ;423 ;ParentControl=164; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__VAT____Control164Caption } { 151 ;Label ;0 ;1692 ;2100 ;423 ;ParentControl=165; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VATAmountLine__VAT_Identifier__Control165Caption } { 156 ;Label ;4620 ;1692 ;2520 ;423 ;ParentControl=169; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VALVATBaseLCY_Control169Caption } { 157 ;Label ;7350 ;1692 ;2520 ;423 ;ParentControl=170; HorzAlign=Right; VertAlign=Bottom; FontSize=9; FontBold=Yes; MultiLine=Yes; DataSetFieldName=VALVATAmountLCY_Control170Caption } { 152 ;TextBox ;0 ;423 ;8190 ;423 ;FontSize=9; FontBold=Yes; SourceExpr=VALSpecLCYHeader; DataSetFieldName=VALSpecLCYHeader } { 153 ;TextBox ;0 ;846 ;8190 ;423 ;FontSize=9; SourceExpr=VALExchRate; DataSetFieldName=VALExchRate } } } { PROPERTIES { SectionType=TransHeader; SectionWidth=18060; SectionHeight=846; } CONTROLS { { 158 ;Label ;0 ;0 ;2100 ;423 ;ParentControl=162; FontSize=9; LeaderDots=Yes; DataSetFieldName=VALVATBaseLCYCaption } { 162 ;TextBox ;4620 ;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Continued; FRB=Report; NLB=Transport]; SourceExpr=VALVATBaseLCY; AutoFormatType=1; DataSetFieldName=VALVATBaseLCY } { 163 ;TextBox ;7350 ;0 ;2520 ;423 ;FontSize=9; SourceExpr=VALVATAmountLCY; AutoFormatType=1; DataSetFieldName=VALVATAmountLCY } } } { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; } CONTROLS { { 164 ;TextBox ;2310 ;0 ;2100 ;423 ;FontSize=9; CaptionML=[ENU=VAT %; FRB=% TVA; NLB=Btw %]; DecimalPlaces=0:5; SourceExpr=VATAmountLine."VAT %"; DataSetFieldName=VATAmountLine__VAT____Control164 } { 165 ;TextBox ;0 ;0 ;2100 ;423 ;FontSize=9; CaptionML=[ENU=VAT Identifier; FRB=Identifiant TVA; NLB=Btw-identificatie]; SourceExpr=VATAmountLine."VAT Identifier"; DataSetFieldName=VATAmountLine__VAT_Identifier__Control165 } { 169 ;TextBox ;4620 ;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=VAT Base; FRB=Base TVA; NLB=Basisbedrag btw]; SourceExpr=VALVATBaseLCY; AutoFormatType=1; DataSetFieldName=VALVATBaseLCY_Control169 } { 170 ;TextBox ;7350 ;0 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=VAT Amount; FRB=Montant TVA; NLB=Btw-bedrag]; SourceExpr=VALVATAmountLCY; AutoFormatType=1; DataSetFieldName=VALVATAmountLCY_Control170 } } } { PROPERTIES { SectionType=TransFooter; SectionWidth=18060; SectionHeight=846; } CONTROLS { { 171 ;Label ;0 ;423 ;2100 ;423 ;ParentControl=175; FontSize=9; LeaderDots=Yes; DataSetFieldName=VALVATBaseLCY_Control175Caption } { 175 ;TextBox ;4620 ;423 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Continued; FRB=Report; NLB=Transport]; SourceExpr=VALVATBaseLCY; AutoFormatType=1; DataSetFieldName=VALVATBaseLCY_Control175 } { 176 ;TextBox ;7350 ;423 ;2520 ;423 ;FontSize=9; SourceExpr=VALVATAmountLCY; AutoFormatType=1; DataSetFieldName=VALVATAmountLCY_Control176 } } } { PROPERTIES { SectionType=Footer; SectionWidth=18060; SectionHeight=846; } CONTROLS { { 180 ;TextBox ;4620 ;423 ;2520 ;423 ;FontSize=9; CaptionML=[ENU=Total; FRB=Total; NLB=Totaal]; SourceExpr=VALVATBaseLCY; AutoFormatType=1; DataSetFieldName=VALVATBaseLCY_Control180 } { 181 ;TextBox ;7350 ;423 ;2520 ;423 ;FontSize=9; SourceExpr=VALVATAmountLCY; AutoFormatType=1; DataSetFieldName=VALVATAmountLCY_Control181 } { 182 ;Label ;0 ;423 ;2100 ;423 ;ParentControl=180; FontSize=9; FontBold=Yes; DataSetFieldName=VALVATBaseLCY_Control180Caption } } } } } { PROPERTIES { DataItemIndent=3; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number) WHERE(Number=CONST(1)); DataItemVarName=Total; } SECTIONS { { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=1692; } CONTROLS { { 119 ;Label ;0 ;423 ;4200 ;423 ;ParentControl=120; FontSize=9; DataSetFieldName=PaymentTerms_DescriptionCaption } { 120 ;TextBox ;4410 ;423 ;10500;423 ;FontSize=9; CaptionML=[ENU=Payment Terms; FRB=Conditions de paiement; NLB=Betalingscondities]; SourceExpr=PaymentTerms.Description; DataSetFieldName=PaymentTerms_Description } { 121 ;Label ;0 ;846 ;4200 ;423 ;ParentControl=122; FontSize=9; DataSetFieldName=ShipmentMethod_DescriptionCaption } { 122 ;TextBox ;4410 ;846 ;10500;423 ;FontSize=9; CaptionML=[ENU=Shipment Method; FRB=Conditions de livraison; NLB=Verzendwijze]; SourceExpr=ShipmentMethod.Description; DataSetFieldName=ShipmentMethod_Description } } } } } { PROPERTIES { DataItemIndent=3; DataItemTable=Table2000000026; DataItemTableView=SORTING(Number) WHERE(Number=CONST(1)); DataItemVarName=Total2; OnPreDataItem=BEGIN IF NOT ShowShippingAddr THEN CurrReport.BREAK; END; } SECTIONS { { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=423; } CONTROLS { { 123 ;Label ;0 ;0 ;6300 ;423 ;FontSize=9; FontBold=Yes; CaptionML=[ENU=Ship-to Address; FRB=Adresse destinataire; NLB=Verzendadres]; DataSetFieldName=Ship_to_AddressCaption } } } { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=846; OnPreSection=BEGIN CurrReport.SHOWOUTPUT := "Sales Invoice Header"."Sell-to Customer No." <> "Sales Invoice Header"."Bill-to Customer No."; END; } CONTROLS { { 125 ;TextBox ;3360 ;0 ;2100 ;423 ;HorzAlign=Left; FontSize=9; SourceExpr="Sales Invoice Header"."Sell-to Customer No."; DataSetFieldName=Sales_Invoice_Header___Sell_to_Customer_No__ } { 124 ;Label ;0 ;0 ;3150 ;423 ;ParentControl=125; FontSize=9; DataSetFieldName=Sales_Invoice_Header___Sell_to_Customer_No__Caption } } } { PROPERTIES { SectionType=Body; SectionWidth=18060; SectionHeight=3384; } CONTROLS { { 126 ;TextBox ;0 ;0 ;6300 ;423 ;FontSize=9; SourceExpr=ShipToAddr[1]; DataSetFieldName=ShipToAddr_1_ } { 127 ;TextBox ;0 ;423 ;6300 ;423 ;FontSize=9; SourceExpr=ShipToAddr[2]; DataSetFieldName=ShipToAddr_2_ } { 128 ;TextBox ;0 ;846 ;6300 ;423 ;FontSize=9; SourceExpr=ShipToAddr[3]; DataSetFieldName=ShipToAddr_3_ } { 129 ;TextBox ;0 ;1269 ;6300 ;423 ;FontSize=9; SourceExpr=ShipToAddr[4]; DataSetFieldName=ShipToAddr_4_ } { 130 ;TextBox ;0 ;1692 ;6300 ;423 ;FontSize=9; SourceExpr=ShipToAddr[5]; DataSetFieldName=ShipToAddr_5_ } { 131 ;TextBox ;0 ;2115 ;6300 ;423 ;FontSize=9; SourceExpr=ShipToAddr[6]; DataSetFieldName=ShipToAddr_6_ } { 51 ;TextBox ;0 ;2538 ;6300 ;423 ;FontSize=9; SourceExpr=ShipToAddr[7]; DataSetFieldName=ShipToAddr_7_ } { 52 ;TextBox ;0 ;2961 ;6300 ;423 ;FontSize=9; SourceExpr=ShipToAddr[8]; DataSetFieldName=ShipToAddr_8_ } } } } } } REQUESTFORM { PROPERTIES { Width=5060; Height=1540; SaveValues=Yes; OnOpenForm=BEGIN InitLogInteraction; RequestOptionsForm.LogInteraction.ENABLED(LogInteraction); END; } CONTROLS { { 1 ;TextBox ;3410 ;0 ;1650 ;440 ;CaptionML=[ENU=No. of Copies; FRB=Nombre de copies; NLB=Aantal exemplaren]; SourceExpr=NoOfCopies } { 21 ;Label ;0 ;0 ;3300 ;440 ;ParentControl=1 } { 2 ;CheckBox ;3410 ;550 ;440 ;440 ;ShowCaption=No; CaptionML=[ENU=Show Internal Information; FRB=Afficher info. internes; NLB=Interne informatie weergeven]; SourceExpr=ShowInternalInfo } { 3 ;Label ;0 ;550 ;3300 ;440 ;ParentControl=2 } { 4 ;CheckBox ;3410 ;1100 ;440 ;440 ;Name=LogInteraction; ShowCaption=No; CaptionML=[ENU=Log Interaction; FRB=Journal interaction; NLB=Interactie registreren]; SourceExpr=LogInteraction } { 5 ;Label ;0 ;1100 ;3300 ;440 ;ParentControl=4 } } } REQUESTPAGE { PROPERTIES { SaveValues=Yes; OnInit=BEGIN LogInteractionEnable := TRUE; END; OnOpenPage=BEGIN InitLogInteraction; LogInteractionEnable := LogInteraction; END; } CONTROLS { { 1900000001;0;Container; ContainerType=ContentArea } { 1900000002;1;Group ; CaptionML=[ENU=Options; FRB=Options; NLB=Opties] } { 1 ;2 ;Field ; CaptionML=[ENU=No. of Copies; FRB=Nombre de copies; NLB=Aantal exemplaren]; SourceExpr=NoOfCopies } { 2 ;2 ;Field ; CaptionML=[ENU=Show Internal Information; FRB=Afficher info. internes; NLB=Interne informatie weergeven]; SourceExpr=ShowInternalInfo } { 4 ;2 ;Field ; Name=LogInteraction; CaptionML=[ENU=Log Interaction; FRB=Journal interaction; NLB=Interactie registreren]; SourceExpr=LogInteraction; Enabled=LogInteractionEnable } } } CODE { VAR Text000@1000 : TextConst 'ENU=Salesperson;FRB=Vendeur;NLB=Verkoper'; Text001@1001 : TextConst 'ENU=Total %1;FRB=Total %1;NLB=Totaal %1'; Text002@1002 : TextConst 'ENU=Total %1 Incl. VAT;FRB=Total %1 TTC;NLB=Totaal %1 incl. btw'; Text003@1003 : TextConst 'ENU=COPY;FRB=COPIE;NLB=KOPIE'; Text004@1004 : TextConst 'ENU=Sales - Invoice %1;FRB=Ventes : Facture %1;NLB=Verkoop - Factuur %1'; Text005@1005 : TextConst 'ENU=Page %1;FRB=Page %1;NLB=Pagina %1'; Text006@1006 : TextConst 'ENU=Total %1 Excl. VAT;FRB=Total %1 HT;NLB=Totaal %1 excl. btw'; GLSetup@1007 : Record 98; ShipmentMethod@1008 : Record 10; PaymentTerms@1009 : Record 3; SalesPurchPerson@1010 : Record 13; CompanyInfo@1011 : Record 79; CompanyInfo1@1045 : Record 79; CompanyInfo2@1046 : Record 79; SalesSetup@1048 : Record 311; Cust@1012 : Record 18; VATAmountLine@1013 : TEMPORARY Record 290; PostedDocDim1@1014 : Record 359; PostedDocDim2@1015 : Record 359; RespCenter@1016 : Record 5714; Language@1017 : Record 8; CurrExchRate@1054 : Record 330; SalesInvCountPrinted@1018 : Codeunit 315; FormatAddr@1019 : Codeunit 365; SegManagement@1020 : Codeunit 5051; SalesShipmentBuffer@1050 : TEMPORARY Record 7190; PostedShipmentDate@1044 : Date; CustAddr@1021 : ARRAY [8] OF Text[50]; ShipToAddr@1022 : ARRAY [8] OF Text[50]; CompanyAddr@1023 : ARRAY [8] OF Text[50]; OrderNoText@1024 : Text[80]; SalesPersonText@1025 : Text[30]; VATNoText@1026 : Text[80]; ReferenceText@1027 : Text[80]; TotalText@1028 : Text[50]; TotalExclVATText@1029 : Text[50]; TotalInclVATText@1030 : Text[50]; MoreLines@1031 : Boolean; NoOfCopies@1032 : Integer; NoOfLoops@1033 : Integer; CopyText@1034 : Text[30]; ShowShippingAddr@1035 : Boolean; i@1036 : Integer; NextEntryNo@1043 : Integer; FirstValueEntryNo@1042 : Integer; DimText@1037 : Text[120]; OldDimText@1038 : Text[75]; ShowInternalInfo@1039 : Boolean; Continue@1040 : Boolean; LogInteraction@1041 : Boolean; VALVATBaseLCY@1052 : Decimal; VALVATAmountLCY@1053 : Decimal; VALSpecLCYHeader@1055 : Text[80]; Text007@1049 : TextConst 'ENU="VAT Amount Specification in ";FRB="D‚tail TVA dans ";NLB="Specificatie btw-bedrag in "'; Text008@1051 : TextConst 'ENU=Local Currency;FRB=Devise soci‚t‚;NLB=Lokale valuta'; VALExchRate@1047 : Text[50]; Text009@1056 : TextConst 'ENU=Exchange rate: %1/%2;FRB=Taux de change : %1/%2;NLB=Wisselkoers: %1/%2'; CalculatedExchRate@1057 : Decimal; Text010@1058 : TextConst 'ENU=Sales - Prepayment Invoice %1;FRB=Ventes - Facture acompte %1;NLB=Verkoop - Vooruitbetalingsfactuur %1'; OutputNo@1059 : Integer; TotalSubTotal@1061 : Decimal; TotalAmount@1062 : Decimal; TotalAmountInclVAT@1064 : Decimal; TotalAmountVAT@1065 : Decimal; TotalInvoiceDiscountAmount@1063 : Decimal; TotalPaymentDiscountOnVAT@1060 : Decimal; Country@1010000 : Record 9; NoText@1010001 : Text[50]; LogInteractionEnable@19003940 : Boolean INDATASET; PROCEDURE InitLogInteraction@1(); BEGIN LogInteraction := SegManagement.FindInteractTmplCode(4) <> ''; END; PROCEDURE FindPostedShipmentDate@6() : Date; VAR SalesShipmentHeader@1000 : Record 110; SalesShipmentBuffer2@1001 : TEMPORARY Record 7190; BEGIN NextEntryNo := 1; IF "Sales Invoice Line"."Shipment No." <> '' THEN IF SalesShipmentHeader.GET("Sales Invoice Line"."Shipment No.") THEN EXIT(SalesShipmentHeader."Posting Date"); IF "Sales Invoice Header"."Order No."='' THEN EXIT("Sales Invoice Header"."Posting Date"); CASE "Sales Invoice Line".Type OF "Sales Invoice Line".Type::Item: GenerateBufferFromValueEntry("Sales Invoice Line"); "Sales Invoice Line".Type::"G/L Account","Sales Invoice Line".Type::Resource, "Sales Invoice Line".Type::"Charge (Item)","Sales Invoice Line".Type::"Fixed Asset": GenerateBufferFromShipment("Sales Invoice Line"); "Sales Invoice Line".Type::" ": EXIT(0D); END; SalesShipmentBuffer.RESET; SalesShipmentBuffer.SETRANGE("Document No.","Sales Invoice Line"."Document No."); SalesShipmentBuffer.SETRANGE("Line No." ,"Sales Invoice Line"."Line No."); IF SalesShipmentBuffer.FIND('-') THEN BEGIN SalesShipmentBuffer2 := SalesShipmentBuffer; IF SalesShipmentBuffer.NEXT = 0 THEN BEGIN SalesShipmentBuffer.GET( SalesShipmentBuffer2."Document No.",SalesShipmentBuffer2."Line No.",SalesShipmentBuffer2."Entry No."); SalesShipmentBuffer.DELETE; EXIT(SalesShipmentBuffer2."Posting Date"); END ; SalesShipmentBuffer.CALCSUMS(Quantity); IF SalesShipmentBuffer.Quantity <> "Sales Invoice Line".Quantity THEN BEGIN SalesShipmentBuffer.DELETEALL; EXIT("Sales Invoice Header"."Posting Date"); END; END ELSE EXIT("Sales Invoice Header"."Posting Date"); END; PROCEDURE GenerateBufferFromValueEntry@2(SalesInvoiceLine2@1002 : Record 113); VAR ValueEntry@1000 : Record 5802; ItemLedgerEntry@1001 : Record 32; TotalQuantity@1003 : Decimal; Quantity@1004 : Decimal; BEGIN TotalQuantity := SalesInvoiceLine2."Quantity (Base)"; ValueEntry.SETCURRENTKEY("Document No."); ValueEntry.SETRANGE("Document No.",SalesInvoiceLine2."Document No."); ValueEntry.SETRANGE("Posting Date","Sales Invoice Header"."Posting Date"); ValueEntry.SETRANGE("Item Charge No.",''); ValueEntry.SETFILTER("Entry No.",'%1..',FirstValueEntryNo); IF ValueEntry.FIND('-') THEN REPEAT IF ItemLedgerEntry.GET(ValueEntry."Item Ledger Entry No.") THEN BEGIN IF SalesInvoiceLine2."Qty. per Unit of Measure" <> 0 THEN Quantity := ValueEntry."Invoiced Quantity" / SalesInvoiceLine2."Qty. per Unit of Measure" ELSE Quantity := ValueEntry."Invoiced Quantity"; AddBufferEntry( SalesInvoiceLine2, -Quantity, ItemLedgerEntry."Posting Date"); TotalQuantity := TotalQuantity + ValueEntry."Invoiced Quantity"; END; FirstValueEntryNo := ValueEntry."Entry No." + 1; UNTIL (ValueEntry.NEXT = 0) OR (TotalQuantity = 0); END; PROCEDURE GenerateBufferFromShipment@8(SalesInvoiceLine@1000 : Record 113); VAR SalesInvoiceHeader@1001 : Record 112; SalesInvoiceLine2@1002 : Record 113; SalesShipmentHeader@1006 : Record 110; SalesShipmentLine@1004 : Record 111; TotalQuantity@1003 : Decimal; Quantity@1005 : Decimal; BEGIN TotalQuantity := 0; SalesInvoiceHeader.SETCURRENTKEY("Order No."); SalesInvoiceHeader.SETFILTER("No.",'..%1',"Sales Invoice Header"."No."); SalesInvoiceHeader.SETRANGE("Order No.","Sales Invoice Header"."Order No."); IF SalesInvoiceHeader.FIND('-') THEN REPEAT SalesInvoiceLine2.SETRANGE("Document No.",SalesInvoiceHeader."No."); SalesInvoiceLine2.SETRANGE("Line No.",SalesInvoiceLine."Line No."); SalesInvoiceLine2.SETRANGE(Type,SalesInvoiceLine.Type); SalesInvoiceLine2.SETRANGE("No.",SalesInvoiceLine."No."); SalesInvoiceLine2.SETRANGE("Unit of Measure Code",SalesInvoiceLine."Unit of Measure Code"); IF SalesInvoiceLine2.FIND('-') THEN REPEAT TotalQuantity := TotalQuantity + SalesInvoiceLine2.Quantity; UNTIL SalesInvoiceLine2.NEXT = 0; UNTIL SalesInvoiceHeader.NEXT = 0; SalesShipmentLine.SETCURRENTKEY("Order No.","Order Line No."); SalesShipmentLine.SETRANGE("Order No.","Sales Invoice Header"."Order No."); SalesShipmentLine.SETRANGE("Order Line No.",SalesInvoiceLine."Line No."); SalesShipmentLine.SETRANGE("Line No.",SalesInvoiceLine."Line No."); SalesShipmentLine.SETRANGE(Type,SalesInvoiceLine.Type); SalesShipmentLine.SETRANGE("No.",SalesInvoiceLine."No."); SalesShipmentLine.SETRANGE("Unit of Measure Code",SalesInvoiceLine."Unit of Measure Code"); SalesShipmentLine.SETFILTER(Quantity,'<>%1',0); IF SalesShipmentLine.FIND('-') THEN REPEAT IF "Sales Invoice Header"."Get Shipment Used" THEN CorrectShipment(SalesShipmentLine); IF ABS(SalesShipmentLine.Quantity) <= ABS(TotalQuantity - SalesInvoiceLine.Quantity) THEN TotalQuantity := TotalQuantity - SalesShipmentLine.Quantity ELSE BEGIN IF ABS(SalesShipmentLine.Quantity) > ABS(TotalQuantity) THEN SalesShipmentLine.Quantity := TotalQuantity; Quantity := SalesShipmentLine.Quantity - (TotalQuantity - SalesInvoiceLine.Quantity); TotalQuantity := TotalQuantity - SalesShipmentLine.Quantity; SalesInvoiceLine.Quantity := SalesInvoiceLine.Quantity - Quantity; IF SalesShipmentHeader.GET(SalesShipmentLine."Document No.") THEN BEGIN AddBufferEntry( SalesInvoiceLine, Quantity, SalesShipmentHeader."Posting Date"); END; END; UNTIL (SalesShipmentLine.NEXT = 0) OR (TotalQuantity = 0); END; PROCEDURE CorrectShipment@7(VAR SalesShipmentLine@1001 : Record 111); VAR SalesInvoiceLine@1000 : Record 113; BEGIN SalesInvoiceLine.SETCURRENTKEY("Shipment No.","Shipment Line No."); SalesInvoiceLine.SETRANGE("Shipment No.",SalesShipmentLine."Document No."); SalesInvoiceLine.SETRANGE("Shipment Line No.",SalesShipmentLine."Line No."); IF SalesInvoiceLine.FIND('-') THEN REPEAT SalesShipmentLine.Quantity := SalesShipmentLine.Quantity - SalesInvoiceLine.Quantity; UNTIL SalesInvoiceLine.NEXT = 0; END; PROCEDURE AddBufferEntry@3(SalesInvoiceLine@1001 : Record 113;QtyOnShipment@1002 : Decimal;PostingDate@1003 : Date); BEGIN SalesShipmentBuffer.SETRANGE("Document No.",SalesInvoiceLine."Document No."); SalesShipmentBuffer.SETRANGE("Line No.",SalesInvoiceLine."Line No."); SalesShipmentBuffer.SETRANGE("Posting Date",PostingDate); IF SalesShipmentBuffer.FIND('-') THEN BEGIN SalesShipmentBuffer.Quantity := SalesShipmentBuffer.Quantity + QtyOnShipment; SalesShipmentBuffer.MODIFY; EXIT; END; WITH SalesShipmentBuffer DO BEGIN "Document No." := SalesInvoiceLine."Document No."; "Line No." := SalesInvoiceLine."Line No."; "Entry No." := NextEntryNo; Type := SalesInvoiceLine.Type; "No." := SalesInvoiceLine."No."; Quantity := QtyOnShipment; "Posting Date" := PostingDate; INSERT; NextEntryNo := NextEntryNo + 1 END; END; LOCAL PROCEDURE DocumentCaption@4() : Text[250]; BEGIN IF "Sales Invoice Header"."Prepayment Invoice" THEN EXIT(Text010); EXIT(Text004); END; BEGIN END. } RDLDATA { 26.45768cm DataSet_Result =Fields!Sales_Invoice_Header_No_.Value =Fields!OutputNo.Value true
0.31746cm =Convert.ToBase64String(Fields!CompanyInfo_Picture.Value) true 2 =Convert.ToBase64String(Fields!CompanyInfo1_Picture.Value) true 1 =Convert.ToBase64String(Fields!CompanyInfo2_Picture.Value) true
0.31746cm2.22222cm 0.3cm 0.3cm 0.3cm 0.9cm8
0.31746cm =Fields!CustAddr_1_.Value + Chr(177) + Fields!CustAddr_2_.Value + Chr(177)+ Fields!CustAddr_3_.Value + Chr(177)+ Fields!CustAddr_4_.Value + Chr(177)+ Fields!CustAddr_5_.Value+Chr(177)+ Fields!CustAddr_6_.Value + Chr(177)+ Fields!CustAddr_7_.Value+Chr(177)+ Fields!CustAddr_8_.Value true 3 =Fields!CompanyAddr_1_.Value + Chr(177) + Fields!CompanyAddr_2_.Value + Chr(177)+ Fields!CompanyAddr_3_.Value + Chr(177)+ Fields!CompanyAddr_4_.Value + Chr(177)+ Fields!CompanyAddr_5_.Value + Chr(177)+ Fields!CompanyAddr_6_.Value true 2 true =Fields!CompanyInfo__Phone_No__Caption.Value + Chr(177) + Fields!CompanyInfo__Phone_No__.Value + Chr(177) + Fields!CompanyInfo__Fax_No__Caption.Value + Chr(177) + Fields!CompanyInfo__Fax_No__.Value + Chr(177)+ Fields!CompanyInfo__Enterprise_No__Caption.Value + Chr(177)+ Fields!CompanyInfo__Enterprise_No__.Value + Chr(177)+ Fields!CompanyInfo__Giro_No__Caption.Value + Chr(177)+ Fields!CompanyInfo__Giro_No__.Value + Chr(177)+ Fields!CompanyInfo__Bank_Name_Caption.Value + Chr(177)+ Fields!CompanyInfo__Bank_Name_.Value + Chr(177)+ Fields!CompanyInfo__Bank_Account_No__Caption.Value + Chr(177)+ Fields!CompanyInfo__Bank_Account_No__.Value true 1 =Fields!Sales_Invoice_Header___Bill_to_Customer_No__Caption.Value + Chr(177) + Fields!Sales_Invoice_Header___Bill_to_Customer_No__.Value + Chr(177) + Fields!VATNoText.Value + Chr(177) + Fields!NoText.Value + Chr(177) + Fields!ReferenceText.Value + Chr(177) + Fields!Sales_Invoice_Header___Your_Reference_.Value + Chr(177) + Fields!Invoice_No_Caption.Value + Chr(177) + Fields!Sales_Invoice_Header___No__.Value + Chr(177) + Fields!OrderNoText.Value + Chr(177) + Fields!Sales_Invoice_Header___Order_No__.Value + Chr(177) + Fields!Sales_Invoice_Header___Posting_Date_Caption.Value + Chr(177) + Fields!Sales_Invoice_Header___Posting_Date_.Value + Chr(177) + Fields!Sales_Invoice_Header___Due_Date_Caption.Value + Chr(177) + Fields!Sales_Invoice_Header___Due_Date_.Value + Chr(177) + Fields!Sales_Invoice_Header___Prices_Including_VAT_Caption.Value + Chr(177) + Cstr(Fields!PricesInclVAT_YesNo.Value) + Chr(177) + First(Fields!FORMAT__Sales_Invoice_Header___Document_Date__0_4_.Value) + Chr(177) + First(Fields!STRSUBSTNO_DocumentCaption_CopyText_.Value) + Chr(177) + Fields!SalesPersonText.Value + Chr(177) + Fields!SalesPurchPerson_Name.Value + Chr(177) + Fields!PageCaption.Value true
0.31746cm 0.3cm 0.3cm 0.3cm 0.3cm 1.2cm7
DataSet_Result
0.423cm true =Fields!Header_DimensionsCaption.Value 5 =Fields!DimText.Value 4 =IIF(Fields!DimensionLoop1_Number.Value=1,False,True) 0.423cm 1 =Fields!DimText.Value =IIF(Fields!DimensionLoop1_Number.Value>1,False,True)
=Fields!DimensionLoop1_Number.Value =1 GreaterThanOrEqual
0.423cm 2 =Code.SetCountRow(cint(countrows("DimensionLoop1"))) 3
1.269cm 3.1746cm 14.92063cm 0.31746cm6
DataSet_Result
Ascending =Fields!Sales_Invoice_Header_No_.Value Ascending =Fields!OutputNo.Value 0.5cm 96 textbox39 =Fields!ShipmentCaption.Value 95 ShipmentCaption =Fields!SalesShipmentBuffer__Posting_Date_.Value 94 SalesShipmentBuffer__Posting_Date_ =Fields!SalesShipmentBuffer_Quantity.Value 93 SalesShipmentBuffer_Quantity 92 textbox45 91 textbox46 90 textbox47 89 textbox48 88 textbox49 =(Fields!ShipmentCaption.Value="") 0.5cm 9 =Fields!Line_DimensionsCaption.Value & " " & Fields!DimText_Control82.Value Line_DimensionsCaption =(Fields!DimText_Control82.Value = "")
=Cstr(Fields!Sales_Invoice_Line_Line_No_.Value) "" GreaterThan
true 0.846cm true =First(Fields!Sales_Invoice_Line__No__Caption.Value) 116 Sales_Invoice_Line__No__Caption true =First(Fields!Sales_Invoice_Line_Description_Control65Caption.Value) 115 true =First(Fields!PostedShipmentDateCaption.Value) 114 PostedShipmentDateCaption true =First(Fields!Sales_Invoice_Line_QuantityCaption.Value) 113 Sales_Invoice_Line_QuantityCaption true =First(Fields!Sales_Invoice_Line__Unit_of_Measure_Caption.Value) 112 Sales_Invoice_Line__Unit_of_Measure_Caption true =First(Fields!Unit_PriceCaption.Value) 111 Unit_PriceCaption true =First(Fields!Sales_Invoice_Line__Line_Discount___Caption.Value) 110 Sales_Invoice_Line__Line_Discount___Caption true =First(Fields!Sales_Invoice_Line__VAT_Identifier_Caption.Value) 109 Sales_Invoice_Line__VAT_Identifier_Caption true =First(Fields!AmountCaption.Value) 108 AmountCaption
9.846cm 1.629cm 4.41cm 1.7cm 1.64203cm 1.291cm 1.93649cm 1.33415cm 1.64203cm 2.2cm
0.5cm true 9 textbox92 true 8 textbox103 true 7 textbox104 true 6 textbox105 true 5 textbox106 true 4 textbox117 true 3 textbox119 true 2 textbox120 true 1 textbox121 0.5cm 15 textbox99 14 textbox100 13 textbox101 12 textbox102 4 true =Fields!SubtotalCaption.Value 11 true =Last(Fields!TotalSubTotal.Value) 10 =IIF(SUM(Fields!Inv__Discount_Amount_.Value)=0,TRUE,FALSE) 0.5cm 21 textbox31 20 textbox38 19 textbox51 18 textbox67 4 true =Fields!Inv__Discount_Amount_Caption.Value 17 true =Last(Fields!TotalInvoiceDiscountAmount.Value) 16 textbox17 =IIF(SUM(Fields!Inv__Discount_Amount_.Value)=0,TRUE,FALSE) 0.5cm 27 textbox94 26 textbox95 25 textbox96 24 textbox97 4 =Fields!TotalText.Value 23 true =Last(Fields!TotalAmount.Value) 22 =Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value) 0.5cm true 36 textbox63 true 35 textbox65 true 34 textbox66 true 33 textbox73 true 32 textbox74 true 31 textbox75 true 30 textbox76 true 29 textbox77 true 28 textbox82 =Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value) 0.5cm 42 textbox111 41 textbox112 40 textbox113 39 textbox114 4 =Fields!TotalExclVATText.Value 38 true =Last(Fields!TotalAmount.Value) 37 =Not(Fields!Sales_Invoice_Header___Prices_Including_VAT_.Value = false and (Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value))) 0.5cm 48 textbox136 47 textbox137 46 textbox138 45 textbox139 4 =last(Fields!VATAmountLine_VATAmountText.Value) 44 true =Last(Fields!TotalAmountVAT.Value) 43 =Not(Fields!Sales_Invoice_Header___Prices_Including_VAT_.Value = false and (Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value))) 0.5cm 54 textbox14 53 textbox15 52 textbox22 51 textbox23 4 =Fields!TotalInclVATText.Value 50 true =Last(Fields!TotalAmountInclVAT.Value) 49 =Not(Fields!Sales_Invoice_Header___Prices_Including_VAT_.Value = false and (Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value))) 0.5cm true 60 textbox26 true 59 textbox27 true 58 textbox28 true 57 textbox29 4 true =Fields!Line_Amount_____Inv__Discount_Amount_____Amount_Including_VAT__Caption.Value 56 textbox30 true =Last(Fields!TotalPaymentDiscountOnVAT.Value) 55 textbox44 =not((Fields!Sales_Invoice_Header___Prices_Including_VAT_.Value = true) and (Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value)) and (Fields!Sales_Invoice_Header___VAT_Base_Discount___.Value <> 0)) 0.5cm 66 textbox80 65 textbox81 64 textbox86 63 textbox98 4 =Fields!TotalInclVATText.Value 62 true =Last(Fields!TotalAmountInclVAT.Value) 61 =Not(Fields!Sales_Invoice_Header___Prices_Including_VAT_.Value = true and (Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value))) 0.5cm true 75 textbox37 true 74 textbox42 true 73 textbox43 true 72 textbox55 true 71 textbox56 true 70 textbox57 true 69 textbox58 true 68 textbox59 true 67 textbox60 =Not(Fields!Sales_Invoice_Header___Prices_Including_VAT_.Value = true and (Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value))) 0.5cm 81 textbox126 80 textbox127 79 textbox131 78 textbox132 4 =Fields!VATAmountLine_VATAmountText.Value 77 true =Last(Fields!TotalAmountVAT.Value) 76 =Not(Fields!Sales_Invoice_Header___Prices_Including_VAT_.Value = true and (Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value))) 0.5cm 4 =Code.SetCountRow(cint(countrows("SalesInvoiceLine"))) 87 textbox152 4 =Fields!TotalExclVATText.Value 83 true =Last(Fields!TotalAmount.Value) 82 =Not(Fields!Sales_Invoice_Header___Prices_Including_VAT_.Value = true and (Sum(Fields!Sales_Invoice_Line__Amount_Including_VAT_.Value) <> Sum(Fields!Sales_Invoice_Line_Amount.Value))) 0.5cm 4 true =Code.GenerateVbCrLf(42 - Code.GetCountRow) textbox3 true textbox36 true textbox50 true textbox52 true textbox53 true textbox54
=Fields!Sales_Invoice_Header_No_.Value
=Fields!Sales_Invoice_Header_No_.Value =Fields!OutputNo.Value =Fields!Sales_Invoice_Line_Line_No_.Value
0.5cm 107 textbox4 8 =Fields!Sales_Invoice_Line_Description.Value 106 textbox6 =Iif(Fields!SalesLineType.Value = " ", false, true) 0.5cm =Fields!Sales_Invoice_Line__No__.Value 105 Sales_Invoice_Line__No__ =Fields!Sales_Invoice_Line_Description.Value 104 =Fields!PostedShipmentDate.Value 103 PostedShipmentDate =Code.BlankZero(Fields!Sales_Invoice_Line_Quantity.Value) 102 Sales_Invoice_Line_Quantity =Fields!Sales_Invoice_Line__Unit_of_Measure_.Value 101 Sales_Invoice_Line__Unit_of_Measure_ =Code.BlankZero(Fields!Sales_Invoice_Line__Unit_Price_.Value) 100 Sales_Invoice_Line__Unit_Price_ =Code.BlankZero(Fields!Sales_Invoice_Line__Line_Discount___.Value) 99 Sales_Invoice_Line__Line_Discount___ =IIF(Trim(Fields!SalesLineType.Value) <> "",Fields!Sales_Invoice_Line__VAT_Identifier_.Value,"") 98 Sales_Invoice_Line__VAT_Identifier_ =Code.BlankZero(Fields!Sales_Invoice_Line__Line_Amount_.Value) 97 Sales_Invoice_Line__Line_Amount_ =Iif(Fields!SalesLineType.Value = " ", true, false)
Ascending =Fields!Sales_Invoice_Header_No_.Value Ascending =Fields!OutputNo.Value Ascending =Fields!Sales_Invoice_Line_Line_No_.Value
1.90476cm17.7847cm5
0.5cm =Fields!VATAmountLine__VAT_Identifier__Control165.Value 3 =Fields!VATAmountLine__VAT____Control164.Value 2 =Fields!VALVATBaseLCY.Value 1 VALVATBaseLCY =Fields!VALVATAmountLCY.Value VALVATAmountLCY
=Fields!VATAmountLine__VAT_Identifier__Control165.Value ="" GreaterThan
0.5cm =First(Fields!VALVATBaseLCY_Control180Caption.Value) 7 6 =Sum(Fields!VALVATBaseLCY.Value) 5 VALVATBaseLCY_1 =Sum(Fields!VALVATAmountLCY.Value) 4 VALVATAmountLCY_1
0.95238cm 4 =First(Fields!VALSpecLCYHeader.Value) 13 VALSpecLCYHeader 0.95238cm 4 =First(Fields!VALExchRate.Value) 12 VALExchRate 0.95238cm true =First(Fields!VATAmountLine__VAT_Identifier__Control165Caption.Value) 11 true =First(Fields!VATAmountLine__VAT____Control164Caption.Value) 10 true =First(Fields!VALVATBaseLCY_Control169Caption.Value) 9 true =First(Fields!VALVATAmountLCY_Control170Caption.Value) 8
3.85714cm 3.32235cm 2.32565cm 2.65788cm 2.65788cm 14.92063cm =(Fields!VATAmountLine__VAT_Identifier__Control165.Value = "") 10.96376cm4
0.52646cm =Fields!VATAmountLine__VAT_Identifier_.Value 6 VATAmountLine__VAT_Identifier_ =Fields!VATAmountLine__VAT___.Value 5 VATAmountLine__VAT___ =Fields!VATAmountLine__Line_Amount_.Value 4 =Fields!VATAmountLine__Inv__Disc__Base_Amount_.Value 3 =Fields!VATAmountLine__Invoice_Discount_Amount_.Value 2 =Fields!VATAmountLine__VAT_Base_.Value 1 VATAmountLine__VAT_Base_ =Fields!VATAmountLine__VAT_Amount_.Value
=Fields!VATAmountLine__VAT_Identifier_.Value ="" GreaterThan
0.52646cm =First(Fields!VATAmountLine__VAT_Base__Control116Caption.Value) 13 12 textbox118 =Sum(Fields!VATAmountLine__Line_Amount_.Value) 11 =Sum(Fields!VATAmountLine__Inv__Disc__Base_Amount_.Value) 10 =Sum(Fields!VATAmountLine__Invoice_Discount_Amount_.Value) 9 =Sum(Fields!VATAmountLine__VAT_Base_.Value) 8 VATAmountLine__VAT_Base__1 =Sum(Fields!VATAmountLine__VAT_Amount_.Value) 7
true 1cm 7 true =First(Fields!VAT_Amount_SpecificationCaption.Value) 21 VAT_Amount_SpecificationCaption 1cm true =First(Fields!VATAmountLine__VAT_Identifier_Caption.Value) 20 VATAmountLine__VAT_Identifier_Caption true =First(Fields!VATAmountLine__VAT___Caption.Value) 19 VATAmountLine__VAT___Caption true =First(Fields!VATAmountLine__Line_Amount__Control140Caption.Value) 18 true =First(Fields!VATAmountLine__Inv__Disc__Base_Amount__Control141Caption.Value) 17 true =First(Fields!VATAmountLine__Invoice_Discount_Amount__Control142Caption.Value) 16 true =First(Fields!VATAmountLine__VAT_Base__Control108Caption.Value) 15 true =First(Fields!VATAmountLine__VAT_Amount__Control109Caption.Value) 14
3.05292cm 3.26608cm 2.28625cm 2.61287cm 2.61287cm 2.28625cm 2.28625cm 2.05763cm 11.75076cm =(Fields!VATAmountLine__VAT_Identifier_.Value = "") 17.4082cm3
0.5cm 2 8 textbox70 =(First(Fields!Sales_Invoice_Header___Sell_to_Customer_No__.Value)= First(Fields!Sales_Invoice_Header___Bill_to_Customer_No__.Value)) 0.5cm 2 =Fields!ShipToAddr_1_.Value 7 ShipToAddr_1__1 0.5cm 2 =Fields!ShipToAddr_2_.Value 6 ShipToAddr_2__1 0.5cm 2 =Fields!ShipToAddr_3_.Value 5 ShipToAddr_3__1 0.52646cm 2 =Fields!ShipToAddr_4_.Value 4 ShipToAddr_4_ 0.52646cm 2 =Fields!ShipToAddr_5_.Value 3 ShipToAddr_5_ 0.5cm 2 =Fields!ShipToAddr_6_.Value 2 ShipToAddr_6_ 0.5cm 2 =Fields!ShipToAddr_7_.Value 1 ShipToAddr_7_ 0.5cm 2 =Fields!ShipToAddr_8_.Value ShipToAddr_8_
=Fields!ShipToAddr_1_.Value ="" GreaterThan
0.95238cm 2 true =First(Fields!Ship_to_AddressCaption.Value) 11 Ship_to_AddressCaption 0.63492cm true =First(Fields!Sales_Invoice_Header___Sell_to_Customer_No__Caption.Value) 10 Sales_Invoice_Header___Sell_to_Customer_No__Caption =First(Fields!Sales_Invoice_Header___Sell_to_Customer_No__.Value) 9 Sales_Invoice_Header___Sell_to_Customer_No__ =(First(Fields!Sales_Invoice_Header___Sell_to_Customer_No__.Value)= First(Fields!Sales_Invoice_Header___Bill_to_Customer_No__.Value))
4.24584cm 13.17175cm 20.31747cm =(Fields!ShipToAddr_1_.Value = "") 17.41759cm2
0.5cm true =Fields!PaymentTerms_DescriptionCaption.Value 3 PaymentTerms_DescriptionCaption_1 =Fields!PaymentTerms_Description.Value 2 PaymentTerms_Description_1 0.5cm true =Fields!ShipmentMethod_DescriptionCaption.Value 1 ShipmentMethod_DescriptionCaption_1 =Fields!ShipmentMethod_Description.Value ShipmentMethod_Description_1
=Fields!ShipmentMethod_Description.Value =Fields!PaymentTerms_Description.Value NotEqual 1cm 5.40103cm 12.03657cm 19.04763cm =(Fields!ShipmentMethod_Description.Value = Fields!PaymentTerms_Description.Value) 17.4376cm1
0.423cm 17.63045cm 5.39683cm =Code.IsNewPage(0,Fields!Sales_Invoice_Header_No_.Value,Fields!OutputNo.Value) true 0.31746cm
Ascending =Fields!Sales_Invoice_Header_No_.Value Ascending =Fields!OutputNo.Value 18.09523cm
2cm Shared TotalRows as Integer Public Function SetCountRow(RowsToAdd as integer) TotalRows = TotalRows + RowsToAdd End Function Public Function GetCountRow() as Integer Return TotalRows End Function Public Function GenerateVbCrLf(ByVal Count as integer) dim Value as String dim i as integer For i = 1 To Count Step 1 Value = Value & " " & VbCrLf Next i Return Value End Function Public Function BlankZero(ByVal Value As Decimal) if Value = 0 then Return "" end if Return Value End Function Public Function BlankPos(ByVal Value As Decimal) if Value > 0 then Return "" end if Return Value End Function Public Function BlankZeroAndPos(ByVal Value As Decimal) if Value >= 0 then Return "" end if Return Value End Function Public Function BlankNeg(ByVal Value As Decimal) if Value < 0 then Return "" end if Return Value End Function Public Function BlankNegAndZero(ByVal Value As Decimal) if Value <= 0 then Return "" end if Return Value End Function REM Reset Page Number: Shared offset as Integer Shared newPage as Object Shared currentgroup1 as Object Shared currentgroup2 as Object Shared currentgroup3 as Object Public Function GetGroupPageNumber(NewPage as Boolean, pagenumber as Integer) as Object If NewPage offset = pagenumber - 1 End If Return pagenumber - offset End Function Public Function IsNewPage(group1 as Object, group2 as Object, group3 as Object) As Boolean newPage = FALSE If Not (group1 = currentgroup1) newPage = TRUE currentgroup1 = group1 currentgroup2 = group2 currentgroup3 = group3 ELSE If Not (group2 = currentgroup2) newPage = TRUE currentgroup2 = group2 currentgroup3 = group3 ELSE If Not (group3 = currentgroup3) newPage = TRUE currentgroup3 = group3 End If End If End If Return newPage End Function Shared Data1 as Object Shared Data2 as Object Shared Data3 as Object Shared Data4 as Object Public Function GetData(Num as Integer, Group as integer) as Object if Group = 1 then Return Cstr(Choose(Num, Split(Cstr(Data1),Chr(177)))) End If if Group = 2 then Return Cstr(Choose(Num, Split(Cstr(Data2),Chr(177)))) End If if Group = 3 then Return Cstr(Choose(Num, Split(Cstr(Data3),Chr(177)))) End If if Group = 4 then Return Cstr(Choose(Num, Split(Cstr(Data4),Chr(177)))) End If End Function Public Function SetData(NewData as Object,Group as integer) If Group = 1 and NewData > "" Then Data1 = NewData End If If Group = 2 and NewData > "" Then Data2 = NewData End If If Group = 3 and NewData > "" Then Data3 = NewData End If If Group = 4 and NewData > "" Then Data4 = NewData End If End Function Shared PictureData1 as Object Shared PictureData2 as Object Shared PictureData3 as Object Public Function GetPicture(Group as integer) as Object if Group = 1 then Return PictureData1 End If if Group = 2 then Return PictureData2 End If if Group = 3 then Return PictureData3 End If End Function Public Function SetPicture(NewData as Object,Group as integer) If Group = 1 and NewData > "" Then PictureData1 = NewData End If If Group = 2 and NewData > "" Then PictureData2 = NewData End If If Group = 3 and NewData > "" Then PictureData3 = NewData End If End Function Sales_Invoice_Header_No_ CompanyInfo2_Picture CompanyInfo1_Picture CompanyInfo_Picture STRSUBSTNO_DocumentCaption_CopyText_ STRSUBSTNO_Text005_FORMAT_CurrReport_PAGENO__ CustAddr_1_ CompanyAddr_1_ CustAddr_2_ CompanyAddr_2_ CustAddr_3_ CompanyAddr_3_ CustAddr_4_ CompanyAddr_4_ CustAddr_5_ CompanyInfo__Phone_No__Caption CompanyInfo__Phone_No__ CustAddr_6_ CompanyInfo__Fax_No__Caption CompanyInfo__Fax_No__ CompanyInfo__Giro_No__Caption CompanyInfo__Giro_No__ CompanyInfo__Bank_Name_Caption CompanyInfo__Bank_Name_ CompanyInfo__Bank_Account_No__Caption CompanyInfo__Bank_Account_No__ Sales_Invoice_Header___Bill_to_Customer_No__Caption Sales_Invoice_Header___Bill_to_Customer_No__ Sales_Invoice_Header___Posting_Date_ VATNoText NoText Sales_Invoice_Header___Due_Date_Caption Sales_Invoice_Header___Due_Date_ SalesPersonText SalesPurchPerson_Name Invoice_No_Caption Sales_Invoice_Header___No__ ReferenceText Sales_Invoice_Header___Your_Reference_ OrderNoText Sales_Invoice_Header___Order_No__ CustAddr_7_ CustAddr_8_ CompanyAddr_5_ CompanyAddr_6_ Sales_Invoice_Header___Posting_Date_Caption FORMAT__Sales_Invoice_Header___Document_Date__0_4_ Sales_Invoice_Header___Prices_Including_VAT_ Sales_Invoice_Header___Prices_Including_VAT_Caption OutputNo PricesInclVAT_YesNo PageCaption CompanyInfo__Enterprise_No__Caption CompanyInfo__Enterprise_No__ DimText Header_DimensionsCaption DimensionLoop1_Number Sales_Invoice_Line__No__Caption Sales_Invoice_Line_Description_Control65Caption Sales_Invoice_Line_QuantityCaption Sales_Invoice_Line__Unit_of_Measure_Caption Unit_PriceCaption Sales_Invoice_Line__Line_Discount___Caption AmountCaption Sales_Invoice_Line__VAT_Identifier_Caption PostedShipmentDateCaption ContinuedCaption Sales_Invoice_Line__Line_Amount_ Sales_Invoice_Line__Line_Amount_Format Sales_Invoice_Line_Description Sales_Invoice_Line__No__ Sales_Invoice_Line_Quantity Sales_Invoice_Line_QuantityFormat Sales_Invoice_Line__Unit_of_Measure_ Sales_Invoice_Line__Unit_Price_ Sales_Invoice_Line__Unit_Price_Format Sales_Invoice_Line__Line_Discount___ Sales_Invoice_Line__Line_Discount___Format Sales_Invoice_Line__Line_Amount__Control70Format Sales_Invoice_Line__VAT_Identifier_ PostedShipmentDate SalesLineType ContinuedCaption_Control85 Sales_Invoice_Line__Line_Amount__Control86Format Inv__Discount_Amount_Caption Inv__Discount_Amount_ Inv__Discount_Amount_Format SubtotalCaption Sales_Invoice_Line__Line_Amount__Control99Format TotalSubTotal TotalSubTotalFormat TotalInvoiceDiscountAmount TotalInvoiceDiscountAmountFormat TotalText Sales_Invoice_Line_Amount Sales_Invoice_Line_AmountFormat TotalAmount TotalAmountFormat Sales_Invoice_Line_Amount_Control90Format Amount_Including_VAT____Amount Amount_Including_VAT____AmountFormat Sales_Invoice_Line__Amount_Including_VAT_ Sales_Invoice_Line__Amount_Including_VAT_Format VATAmountLine_VATAmountText TotalExclVATText TotalInclVATText TotalAmountInclVAT TotalAmountInclVATFormat TotalAmountVAT TotalAmountVATFormat Line_Amount_____Inv__Discount_Amount_____Amount_Including_VAT__Caption Line_Amount_____Inv__Discount_Amount_____Amount_Including_VAT__ Line_Amount_____Inv__Discount_Amount_____Amount_Including_VAT__Format Sales_Invoice_Header___VAT_Base_Discount___ Sales_Invoice_Header___VAT_Base_Discount___Format TotalPaymentDiscountOnVAT TotalPaymentDiscountOnVATFormat Amount_Including_VAT____Amount_Control62Format Sales_Invoice_Line_Amount_Control63Format Sales_Invoice_Line__Amount_Including_VAT__Control71Format Sales_Invoice_Line_Document_No_ Sales_Invoice_Line_Line_No_ SalesShipmentBuffer__Posting_Date_ SalesShipmentBuffer_Quantity SalesShipmentBuffer_QuantityFormat ShipmentCaption DimText_Control82 Line_DimensionsCaption VATAmountLine__VAT___Caption VATAmountLine__VAT_Base__Control108Caption VATAmountLine__VAT_Amount__Control109Caption VAT_Amount_SpecificationCaption VATAmountLine__VAT_Identifier_Caption VATAmountLine__Inv__Disc__Base_Amount__Control141Caption VATAmountLine__Line_Amount__Control140Caption VATAmountLine__Invoice_Discount_Amount__Control142Caption VATAmountLine__VAT_Base_Caption VATAmountLine__VAT_Base_ VATAmountLine__VAT_Base_Format VATAmountLine__VAT_Amount_ VATAmountLine__VAT_Amount_Format VATAmountLine__Line_Amount_ VATAmountLine__Line_Amount_Format VATAmountLine__Inv__Disc__Base_Amount_ VATAmountLine__Inv__Disc__Base_Amount_Format VATAmountLine__Invoice_Discount_Amount_ VATAmountLine__Invoice_Discount_Amount_Format VATAmountLine__VAT___ VATAmountLine__VAT___Format VATAmountLine__VAT_Base__Control108Format VATAmountLine__VAT_Amount__Control109Format VATAmountLine__VAT_Identifier_ VATAmountLine__Line_Amount__Control140Format VATAmountLine__Inv__Disc__Base_Amount__Control141Format VATAmountLine__Invoice_Discount_Amount__Control142Format VATAmountLine__VAT_Base__Control112Caption VATAmountLine__VAT_Base__Control112Format VATAmountLine__VAT_Amount__Control113Format VATAmountLine__Line_Amount__Control110Format VATAmountLine__Inv__Disc__Base_Amount__Control114Format VATAmountLine__Invoice_Discount_Amount__Control118Format VATAmountLine__VAT_Base__Control116Caption VATAmountLine__VAT_Base__Control116Format VATAmountLine__VAT_Amount__Control117Format VATAmountLine__Line_Amount__Control132Format VATAmountLine__Inv__Disc__Base_Amount__Control133Format VATAmountLine__Invoice_Discount_Amount__Control134Format VATAmountLine__VAT____Control164Caption VATAmountLine__VAT_Identifier__Control165Caption VALVATBaseLCY_Control169Caption VALVATAmountLCY_Control170Caption VALSpecLCYHeader VALExchRate VALVATBaseLCYCaption VALVATBaseLCY VALVATBaseLCYFormat VALVATAmountLCY VALVATAmountLCYFormat VATAmountLine__VAT____Control164 VATAmountLine__VAT____Control164Format VATAmountLine__VAT_Identifier__Control165 VALVATBaseLCY_Control169Format VALVATAmountLCY_Control170Format VALVATBaseLCY_Control175Caption VALVATBaseLCY_Control175Format VALVATAmountLCY_Control176Format VALVATBaseLCY_Control180Format VALVATAmountLCY_Control181Format VALVATBaseLCY_Control180Caption PaymentTerms_DescriptionCaption PaymentTerms_Description ShipmentMethod_DescriptionCaption ShipmentMethod_Description Ship_to_AddressCaption Sales_Invoice_Header___Sell_to_Customer_No__ Sales_Invoice_Header___Sell_to_Customer_No__Caption ShipToAddr_1_ ShipToAddr_2_ ShipToAddr_3_ ShipToAddr_4_ ShipToAddr_5_ ShipToAddr_6_ ShipToAddr_7_ ShipToAddr_8_ DummyDataSource DataSet Result SQL 8a468d3b-c480-4411-94c6-261dc7040a5b 11in 8.5in =User!Language 1.5cm 10.03269cm true true 0.31746cm 8.25397cm =Code.SetPicture(ReportItems!CompanyInfo2_Picture.Value,3) true 0.95238cm 57 0.31746cm 6.98413cm =Code.SetPicture(ReportItems!CompanyInfo1_Picture.Value,2) true 0.95238cm 56 0.31746cm 5.71429cm =Code.SetPicture(ReportItems!CompanyInfo_Picture.Value,1) true 0.95238cm 55 0.31746cm 4.12698cm =Code.SetData(ReportItems!SalesHdrInfo.Value,4) true 0.95238cm 54 0.31746cm 2.85714cm =Code.SetData(ReportItems!CompanyInfo.Value,3) true 0.95238cm 53 0.31746cm 1.5873cm =Code.SetData(ReportItems!CompanyAddr.Value,2) true 0.95238cm 52 0.31746cm 0.31746cm =Code.SetData(ReportItems!CustAddr.Value,1) true 0.95238cm 51 0.42889cm 14.47939cm 9.1749cm =Code.GetData(14,4) 2.1cm 50 0.42889cm 11.11111cm 9.1749cm =Code.GetData(13,4) 3.15cm 49 0.42889cm 14.47939cm 8.323cm =Code.GetData(10,4) 2.1cm 48 0.42889cm 11.11111cm 8.323cm =Code.GetData(9,4) 3.15cm 47 0.423cm 11.11111cm 7.12005cm =Code.GetData(17,4) 4.41cm 46 0.423cm 12.38095cm 0.84305cm =Code.GetGroupPageNumber(ReportItems!NewPage.Value,Globals!PageNumber) 0.95238cm 45 0.423cm 11.11111cm 0.42005cm =Code.GetData(18,4) 6.3cm 44 0.423cm 0.50521cm 1.68989cm =Code.GetData(1,1) 6.3cm 43 0.423cm 11.11111cm 1.68905cm =Code.GetData(1,2) 6.3cm 42 0.423cm 0.50521cm 2.11289cm =Code.GetData(2,1) 6.3cm 41 0.423cm 11.11111cm 2.11205cm =Code.GetData(2,2) 6.3cm 40 0.423cm 0.50521cm 2.53589cm =Code.GetData(3,1) 6.3cm 39 0.423cm 11.11111cm 2.53505cm =Code.GetData(3,2) 6.3cm 38 0.423cm 0.50521cm 2.95889cm =Code.GetData(4,1) 6.3cm 37 0.423cm 11.11111cm 2.95805cm =Code.GetData(4,2) 6.3cm 36 0.423cm 0.50521cm 3.38189cm =Code.GetData(5,1) 6.3cm 35 0.423cm 13.42111cm 4.22705cm =Code.GetData(2,3) 4.2cm 34 0.423cm 0.50521cm 3.80489cm =Code.GetData(6,1) 6.3cm 33 0.423cm 13.42111cm 4.65005cm =Code.GetData(4,3) 4.2cm 32 0.423cm 13.42111cm 5.07305cm =Code.GetData(6,3) 4.2cm 31 0.423cm 13.42111cm 5.49605cm =Code.GetData(8,3) 4.2cm 30 0.423cm 13.42111cm 5.91905cm =Code.GetData(10,3) 4.2cm 29 0.423cm 13.42111cm 6.34205cm =Code.GetData(12,3) 4.2cm 28 0.423cm 3.86521cm 7.1889cm =Code.GetData(2,4) 2.1cm 27 0.423cm 0.50521cm 8.03489cm =Code.GetData(3,4) 3.15cm 26 0.423cm 3.86521cm 8.03489cm =Code.GetData(4,4) 4.2cm 25 0.423cm 14.47939cm 8.7519cm =Code.GetData(12,4) 2.1cm 24 0.423cm 0.50521cm 8.4579cm =Code.GetData(19,4) 3.15cm 23 0.423cm 3.86521cm 8.4579cm =Code.GetData(20,4) 6.3cm 22 0.423cm 14.47939cm 7.9cm =Code.GetData(8,4) 2.1cm 21 0.42805cm 0.50521cm 8.88089cm =Code.GetData(5,4) 3.15cm 20 0.42805cm 3.86521cm 8.88089cm =Code.GetData(6,4) 6.3cm 19 0.423cm 0.50521cm 4.22789cm =Code.GetData(7,1) 6.3cm 18 0.423cm 0.50521cm 4.6509cm =Code.GetData(8,1) 6.3cm 17 0.423cm 11.11111cm 3.38105cm =Code.GetData(5,2) 6.3cm 16 0.423cm 11.11111cm 3.80405cm =Code.GetData(6,2) 6.3cm 15 14.47939cm 9.6038cm =Code.GetData(16,4) 2.1cm 14 0.423cm 11.11111cm 0.84305cm =Code.GetData(21,4) 1.05905cm 13 0.423cm 11.11111cm 4.22705cm =Code.GetData(1,3) 2.1cm 12 0.423cm 11.11111cm 4.65005cm =Code.GetData(3,3) 2.1cm 11 0.423cm 11.11111cm 5.07305cm =Code.GetData(5,3) 2.1cm 10 0.423cm 11.11111cm 5.49605cm =Code.GetData(7,3) 2.1cm 9 0.423cm 11.11111cm 5.91905cm =Code.GetData(9,3) 2.1cm 8 0.423cm 11.11111cm 6.34205cm =Code.GetData(11,3) 2.1cm 7 0.423cm 0.50521cm 7.1889cm =Code.GetData(1,4) 3.15cm 6 0.423cm 11.11111cm 8.7519cm =Code.GetData(11,4) 3.15cm 5 0.423cm 11.11111cm 7.9cm =Code.GetData(7,4) 3.15cm 4 11.11111cm 9.6038cm =Code.GetData(15,4) 3.15cm 3 3.96cm 0.25429cm image/bmp AutoSize Database