Loop Detailed Cust. Ledger Entry Values in Report

Hi All, (again)

 

I would like to ask for help for my rdlc report.

i'll cut to the chase.

I have a Customer, and in my report.

the open Entries. customer's Ledger Entries. should be present in my report(already did this)

and then I'm want to show all of the lines in the Detailed Cust. Ledger Entries of that line in Cust. Ledger Entries. Regardless The Document type.

however, my report only displays the last amount in the first line in my report

 

Hope you could Help Me Thanks!

  • Hii,
    I think you did not use looping the line in repeat until, What coding you did for this ?

  • In reply to Akkrahul:

    Hi i did use Looping
    Repeat Until. but in my layout it only shows 1 line from the detailed cust. ledger entries

    here's my code


    DetLedgEntry.RESET;
    DetLedgEntry.SETRANGE(DetLedgEntry."Cust. Ledger Entry No.",DtldCustLedgEntries."Cust. Ledger Entry No.");
    DetLedgEntry.SETRANGE(DetLedgEntry."Entry Type",DetLedgEntry."Entry Type"::Application);
    IF DetLedgEntry.FINDFIRST THEN BEGIN REPEAT
    DocNoCustLedgEntr := DetLedgEntry."Document No.";
    PaidAmount := ROUND(DetLedgEntry.Amount,0.001);
    MESSAGE(FORMAT(PaidAmount));
    UNTIL DetLedgEntry.NEXT = 0;
    END
  • In reply to Adrian001:

    Hi,

        Please change your code, in place of FINDFIRST you have to use FINDSET and Remove BEGIN and END.

     

     

    DetLedgEntry.RESET;

    DetLedgEntry.SETRANGE(DetLedgEntry."Cust. Ledger Entry No.",DtldCustLedgEntries."Cust. Ledger Entry No.");

    DetLedgEntry.SETRANGE(DetLedgEntry."Entry Type",DetLedgEntry."Entry Type"::Application);

    IF DetLedgEntry.FINDSET THEN

     REPEAT

         DocNoCustLedgEntr := DetLedgEntry."Document No.";

         PaidAmount := ROUND(DetLedgEntry.Amount,0.001); 

         MESSAGE(FORMAT(PaidAmount));

    UNTIL DetLedgEntry.NEXT = 0;

Related