A new "field A" field added to the Vendor table and Vendor Card will help calculate what the "Field B" for an Item needs to be that has an Item Category Code that matches the value set in the "Field C" field on the Inventory Setup. Validation will be added to ensure that a value greater than 100 cannot be entered in the "field A" field on the Vendor Card. Anytime the "field A" field on the Vendor card is updated the "field B" for all Items that have an Item Category Code that matches the "field C" on the Inventory Setup will be recalculated.
i created fields in necessary tables and pages.
0
Answers
You did not finish your post? Where is the question?
my requirement was i had a "field A" in item and "field B" in vendor table and "field C" in inventory table.Anytime the "field A" field on the Vendor card is updated the "field B" for all Items that have an Item Category Code that matches the "field C" on the Inventory Setup will be recalculated.for this i tried to write code as follow
InventorySetup.GET;
Vend.GET;
item.RESET;
//item.SETRANGE("Vendor No.",Vend."No.");
IF item.FINDSET THEN
REPEAT
item.SETRANGE("Item Category Code",InventorySetup."field C" );
IF (item."Vendor No." <> "Vendor No.") AND ("Vendor No." <> '')
THEN
IF Vend.GET("Vendor No.") THEN
"field B":= vend."field B"
UNTIL Rec.NEXT = 0
but it shows wrror message and also not updated the value in item card.
Thanks in advance...
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
if you don't mind would you please Elaborate...
1. Why Vend.GET; ? - it probably produces error, or gets always the first record
2. What is the Rec variable?
3. Why changing values in Rec without MODIFY?
4. Why changing position in Rec?
5. Where is your code located?