alexa-tracking

Main Content

1024
1024
KASKUS
51
244
https://www.kaskus.co.id/thread/5305a41e41cb17532c8b46a9/ask-delphi---fast-report
[ASK] Delphi - Fast Report
Siang gan

Ane lagi nyusun laporan hutang, nah terkendala saat mau nampilkan saldo hutangnya secara runing balance.

Spoiler for laporan:


Spoiler for desain:


Quote:var
TextFilter : String;
Debit, Credit : Currency;

procedure MasterData1OnBeforePrint(Sender: TfrxComponent);
begin
MasterData1.Visible := <Account Payable."DETAILNOINDEX"> <> <Account Payable."MASTERNOINDEX">;
mNoJurnal.Tag := <Account Payable."DETAILNOINDEX">;

Credit := 0;
Debit := 0;

if <Account Payable."DETAILAMOUNT"> < 0 then
Credit := - <Account Payable."DETAILAMOUNT"> * <Account Payable."MASTERCURRENCYRATE">
else
Debit := <Account Payable."DETAILAMOUNT"> * <Account Payable."MASTERCURRENCYRATE"> ;
end;

procedure GroupHeader2OnBeforePrint(Sender: TfrxComponent);
begin
mMasterDebit.Text := '[0]' ;
mMasterCredit.Text := '[0]';
mNoJurnalMaster.Tag :=<Account Payable."MASTERNOINDEX">;
if <Account Payable."DETAILAMOUNT"> > 0 then
mMasterDebit.Text := '[<Account Payable."DETAILAMOUNT"> * <Account Payable."MASTERCURRENCYRATE">]'
else
mMasterCredit.Text := '[-<Account Payable."DETAILAMOUNT"> * <Account Payable."MASTERCURRENCYRATE">]';
end;


begin
FilterAccountStatement(8000, // Account Payable With Detail = 8000
TextFilter,
'MASTERNAMECODE, MASTERREFERENCENO, DETAILNOINDEX',// Column Oder
True // Is Display Detail
);
Memo15.Text := TextFilter;
end.


Jadi yang dikolom saldo sebelah kanan itu ane maunya saldo runing balance, yaitu saldo sebelumnya ditambah Credit lalu dikurangi Debit.


Mohon bantuannya agan-agan suhu