I'm stuck on this. From the "Creditor Cheque/EFT Payment" form, in need to access the "Creditor Purchase" LINE ITEM associated with a specific payment LINE ITEM.
In the database, it looks like there's a line by line association between CR_BatchPayLines and CR_Trans, but only an overall batch association between CR_Trans and CR_BatchTranLines, making it impossible to traverse from a payment CR_BatchPayLinesID back to it's originating purchase ReceiptLineID.
Please refer to the attached spreadsheet for an illustration.
Alternatively, in code, I am working with a
- Code: Select all
foreach (clsPayLineInvoice paymentLine in creditor.InvoicePaymentLines)
Can you tell me what I'm missing, or advise?
Cheers,
Neil.