I have the following process:
If ARInvoiceHeader.TotalItems>0 Then
CREATE Journal FOR EACH ARInvoiceLine WITH Journal.HeaderID=ARInvoiceHeader.ID,
Journal.MyCustomerID=ARInvoiceHeader.MyCustomerID,
Journal.Date=ARInvoiceHeader.Date,
Journal.DocumentNo=ARInvoiceHeader.DocumentNo,
Journal.Type=ARInvoiceLine.Type,
Journal.MyAccountID=ARInvoiceLine.MyAccountID,
Journal.TrxAmount=ARInvoiceLine.GrossAmount*ARInvoiceLine.Flag
The bold row...
Flag is default as '-1' in the ARInvoiceLine Object.
The transations I have entered for the GrossAmount:
Row 1: 1000
Row 2: 2000
Row 3: 3000
And I expected the result in the Journal Object as:
Row 1: -1000
Row 2: -2000
Row 3: -3000
But the result showed in the Journal Object as:
Row 1: -1000
Row 2: -1000
Row 3: -1000
How come? Where I did wrong?
Please help.. thanks..