Customer Ledger Entries and Sales Invoice Header

gulamdastagirgulamdastagir Member Posts: 411
Hi Navies

The Customer Statement display the Invoice Documents on it.

for eg Customer XYZ
Doc Number
SI-1
SI-2
SI-3
.
.
.

Is there a way we can print the sales invoice report filtered only the Document Numbers SI1,SI2,SI3...as displayed on the Customer Statement.
Regards,

GD

Comments

  • Alex_ChowAlex_Chow Member Posts: 5,063
    Yes. Just print the sales invoice with the filter SI-1, SI-2, etc... on the No. field.
  • gulamdastagirgulamdastagir Member Posts: 411
    Alex

    I am printing 2 reports to pdf printer and attaching them to email.

    The first report is a "customer XYZ " stmt showing sales invoices SI-1,SI-2,SI-3...

    The Second report 206 shows all the invoices for the Customer XYZ.

    But i want to display only the Invoices which are displayed in Statement ie. SI1,SI2,SI3 and not ALL

    Please suggest solving this in C/AL

    Thanks
    Regards,

    GD
  • AdamRoueAdamRoue Member Posts: 1,283
    Report 206 is the sales invoice report, therefore to filter this to show the ones you have on your statement you have to "individually" define the invoices as Alex states.

    Not sure what you are trying to achieve really, seems strange to run this report at this stage, so difficult to comment.
    The art of teaching is clarity and the art of learning is to listen
  • gulamdastagirgulamdastagir Member Posts: 411
    please try to understand from a developers perspective.

    the customer stmt filters the customer ledger entrries and displays the sales invoices on it

    Now purely using code can i print only those invoices that are shown on the stmt?

    ](*,)
    Regards,

    GD
  • David_SingletonDavid_Singleton Member Posts: 5,479
    Hi Navies

    The Customer Statement display the Invoice Documents on it.

    for eg Customer XYZ
    Doc Number
    SI-1
    SI-2
    SI-3
    .
    .
    .

    Is there a way we can print the sales invoice report filtered only the Document Numbers SI1,SI2,SI3...as displayed on the Customer Statement.


    There are many solutions, here are two;

    1/ On each line of the statement, call the invoice report (including all your pdf code) so that the pdf for each invocie is created as it is printed on the statement. I am not sure what PDF converter you are using, so it may not be possible to recursively call.

    2/ Whilst running the statement, build up a filter InvoiceFilter += "|"+"Document No." which will create the "SI1|SI2|SI3" filter. The create a function in the Statement report that returns this "filter" back to the caller. Then just run the invoice report with this new filter.
    David Singleton
Sign In or Register to comment.