output journal menu field

mark_christsmark_christs Member Posts: 156
Dear All experts,
I have create a new field and I want it could be posted to capacity ledger entry. And it will be posted using output journal, but I can't put the new field in the field menu table when I open output journal form. COuld you please let me know if there is a certain table for output journal ? or how to put the new field to output journal form ?
I appreciate so much for your answer.


rgds,
Mark

Comments

  • krikikriki Member, Moderator Posts: 9,118
    Output journals use table 83:"Item Journal Line". So you have to put it in this table and then you can put the field on the output journal.

    You also have to put the field in 5832:"Capacity Ledger Entry" and put it on the form where you want to see it (probably form 5832:"Capacity Ledger Entries").

    Now you have also to move the field from table 83 to table 5832. This you have to program in Codeunit 22:"Item Jnl.-Post Line".
    Search for function "InsertCapLedgEntry". In this function you have to pass the field from table 83 to table 5832. The code will be like this:
    CapLedgEntry.INIT;
      CapLedgEntry."Entry No." := CapLedgEntryNo;
    
    // START NEW CODE
      CapLedgEntry."Your New Field" := "Your New Field";
    // STOP NEW CODE
    
      CapLedgEntry."Operation No." := "Operation No.";
    

    And that is it.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • mark_christsmark_christs Member Posts: 156
    Thanks a lot for your reply and correct answers. I will try to do that. In the morning of today here in my country, I posted this question and in the afternoon before I open this mibuso.com I actually have known about item journal line is the source of output journal. I put the new fields into cap. ledger entry and item journal line table. I give some codes on the new field-onvalidate () and also in production journal post C/AL editor. But not work. but now, in this night here in my country, you have given me a new solution. I was very stressful beforehand because everytime I post the journal and filled the new field, but there is nothing filled in the new field on the capacity ledger entries.
    I will try to apply your sugestion. I appreciate it so much.I have created in the machine card some fields relate to lean metric. I think it is possible to do that.


    rgds,
    mark
  • krikikriki Member, Moderator Posts: 9,118
    In general you have to program it to transfer fields from 1 table to another.
    The only tables that go automatically are T36,T37,T38,T39 to their posted document-tables.
    But if you want a field from those to G/L entries or Item ledger Entries or other entry-tables, you have to do it manually. And you have to do it twice.
    -Sales/Purchase Line => item journal Line => item ledger entry.
    -Sales/Purchase header => General journal line => G/L Entry.

    And so on...
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • mark_christsmark_christs Member Posts: 156
    Thanks a lot for your reply and prompt answer. I will try to continue what I want and try to using your answer.


    rgds,
    Mark
Sign In or Register to comment.