Printing Country/Region of Origin Code Field from Item Table in Sales Order Line.

mysamzamysamza Posts: 12Member
I need to print the Country/Region of Origin Code from the Item Card on the Line Items of the Order Confirmation report I am modifying.
Here is what I have done so far but failed to make it work.

I first wrote the following code on the Sales Line's OnAfterRecordTrigger

IF ItemCont.GET("Sales Line"."No.") then;

ItemCont is a variable of record type for Item Table.

Then, in the dataitem(RoundLoop; "Integer") I wrote the following code;

column("Goods"; ItemCont."Country/Region of Origin Code")
{

}
And added the Goods field in RDL to the Line Table.

Thanks in Advance for the Help.

Answers

  • JuhlJuhl Posts: 664Member
    Make sure you use the right sales line variable to get item.
    When using loops, sometimes there are 2 line variables. Like “Sales Line” and SalesLine.
    Follow me on my blog juhl.blog
  • SanderDkSanderDk Posts: 248Member
    What error are you getting?
    For help, do not use PM, but use forum instead, perhaps other people have the same question, or better answers.
  • mysamzamysamza Posts: 12Member
    It won't print. I was adding the code to GET it in the Sales Line Dataitem. I had to do it in the RoundLoop. I got it fixed!
Sign In or Register to comment.