Dear all,
I am making a customization on form 99000818 (Prod. Order Compoenet). Added 2 fields, LocCode and BinCode, and user can specify a location and bin. When he pushes a "Update" button. All component lines for that production order will be udpated with same location code and bin code, so that warehouse is always putting the picked items to 1 bin.
I have worked a bit on the programming, but can't work it out. I need to move cursor the every line to make it works. Here comes my code.
OnPush() of the UPDATE button
"Location Code" := LocCode;
"Bin Code" := 'B1';
COMMIT;
CurrForm.UPDATE;
How can I modify this to have all lines update at once?
0
Comments
hi..
can u tell me on what base you have been changing the value of loccode and B1 for each record.
rest of the all i think you should have to use a function with rec parameter on that same form
and call it from update button push..
Vijay Gupta
We activated the receipt and pick for the raw material location. To have a full picture on how many items are in-stock and how many items are picked (treat as WIP, but may not consume in real time), we changed the location code and bin code in component lines, so that every time the warehouse pick is from stock to B1. Then items in B1 are the "WIP" and we can have very accurate inventory.
I have also tried rec."Location Code", but it does the same. Originally I wanted to get that set of records and then modify, but it fails to recognize "Prod. Order Component" table, and so I tried this.
Do you have any further idea how to make it? [-o<
My Blog - nav.education
I second this... please, ERP is not a toy... [-o<
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.
I do something similar with my Payment journal using a REPEAT & UNTIL. I like to have the Description Line Say (Check Payment "& the date here")
so instead of typing it in everytime I made an Button that runs thru the lines updating the description of each entry.
It looks like this.
Perhaps you're looking for somthing similar with just changing the location. Just like I used the GenJnlLine - you'll be using Prodction order line (or whatever it's called - we don't use that) Don't forget to validate! This description does not need validation but a location code is different.
VALIDATE("Location Code",LocCode);
I'm assuming these new fields are located on a header where the change is made once and you want all the lines to be updated on a push of a button.
Another example using a sales header & updating lines
1)I Always like a double checking question.
2)Set the range of the date you're looking for.
3)Find & Repeat until done.
http://www.BiloBeauty.com
http://www.autismspeaks.org