How to post individual lines through codeunit 80

os2013os2013 Member Posts: 11
Sorry if this is a silly question but I ask anyway:
I have a client request for i.e. a Sales Invoice with lines G/L Acc. No. 11200 (cash) The client wants to enter multiple lines with different amounts but to the same customer. This must appear in the G/L ledger entries as separate lines instead of the standard where the invoice is registered as one entry with the total amount. (pls. don't ask why they want it...they just do) I am looking through CU 80 but am having trouble locating where the total amount is calculated. Can anybody guide me in the right direction? Thx in advance.

Comments

  • Miklos_HollenderMiklos_Hollender Member Posts: 1,598
    Well in the worst case you could try having a Global Dimension 1 or 2 different for each line, I think this would force separation of the G/L lines as they are always split by global dimension. Test this, I am not fully sure.

    You can also search for InvPostingBuffer in CU80.
  • geordiegeordie Member Posts: 655
    I agree with Miklos Hollender's suggestion.
    Otherwise, if you need to replicate exactly the invoice lines in G/L entries you need to add the line no. as new key field in table Invoice Post. Buffer and manage it in PrepareSales function.

    Hope this helps.
  • os2013os2013 Member Posts: 11
    Thanks guys - yes, I think I got it now :D
Sign In or Register to comment.