I am importing Items via a dataport. After some help from a previous post, the VALIDATE is creating the correct entry in the DefaultDimension table, however, the "Value Posting" field is not populated.
I see that VALIDATE is creating the DefaultDimension record, but then would I need to select it and MODIFY?
Here is the code I am currently using. Thanks in advance for any help.
ITEM - OnAfterImportRecord()
Item.INIT;
Item."No." := varNo;
Item.INSERT;
"Item Unit of Measure".INIT;
"Item Unit of Measure"."Item No." := varNo;
"Item Unit of Measure".Code := varUnit;
"Item Unit of Measure".INSERT;
Item.VALIDATE ("Global Dimension 1 Code", varGlobalDim1Code);
Item.VALIDATE ("Base Unit of Measure", varUnit);
Item.MODIFY;
Comments
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
I must have to do something because right now the Value Posting field is not getting populated. According to the data team here, they would like to see a value of 2 in there.
So I would think that either I need to code for this, OR I need to have something setup somewhere that the validation can draw from in order to determine what value really goes in that field. Right?
This code will give the value "Same Code" for the dimension 1 used in the Item table.
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!