Hope someone will be able to tell me how to get through this error message.
Here is the situation:
I am running the Adjust Cost - Item entries batch job and
Costing method is Average for all Items and
Location mandatory = yes
When trying to run the batch job I get an error message stating that I must specify New location code in Item journal line Journal Template name = '', journal batch name='', Line no.=0.
The thing is that the Item Ledger Entry that the batch job stops on is a Transfer entry from one Location code to another.
In the Item Ledger Entry table there is no field for this, but there is one in the Item journal line.
The system uses this to split the transfer into two Item ledger entries but does not keep this field in the item entry.
I can get through this by taking the location mandatory option off but that to me is a short term solution.
any help is appreciated.
Regards
Steini
0
Comments
To solve this question perform the following correction on Codeunit
21"Item Jnl.-Check Line":
Function RunCheck: Only check for new location if Quantity <> 0:
Before:
IF (InvtSetup."Location Mandatory") AND
("Value Entry Type" = "Value Entry Type"::"Direct Cost")
THEN BEGIN
IF Quantity <> 0 THEN
TESTFIELD("Location Code");
IF "Entry Type" = "Entry Type"::Transfer THEN
TESTFIELD("New Location Code");
END;
After:
IF (InvtSetup."Location Mandatory") AND
("Value Entry Type" = "Value Entry Type"::"Direct Cost") AND
(Quantity <> 0)
THEN BEGIN
TESTFIELD("Location Code");
IF "Entry Type" = "Entry Type"::Transfer THEN
TESTFIELD("New Location Code");
END;
Regards,
Luís Nunes