Newbies Pascal_82 Posted March 19, 2011 Newbies Posted March 19, 2011 Hi there ! I have a database of items I have in stock with a reorder level field and a database of purchase orders. What I want to do is when I create a new purchase order, all the items that need to be reorder appears automaticaly in the new purchase order. Is it possible to do this with portals ? Thanks !
bcooney Posted March 19, 2011 Posted March 19, 2011 It can be done with a looping script. Not all items are ordered from the same vendor, right? So, you'd need to find all items that need to be reordered. Sort by vendor. Then loop, creating a PO and POLineItems whenever you encounter a new vendor. This is one of those scripts that makes you love Filemaker, btw.
Newbies Pascal_82 Posted March 20, 2011 Author Newbies Posted March 20, 2011 I'm maybe a noob, but I don't understand what you mean by a loop script. I know how to find what items that I need, but I don't understand the script part. BTW, I just have only one vendor !
bcooney Posted March 20, 2011 Posted March 20, 2011 In order to do this, you'll need to study up on scripting. If you only have one vendor, it's much easier. You can find all the items to reorder, then create a new PO (in a new window), capture its ID and then import your items into a POLineItems table, setting the parent POID. Find Items that need reorder. Create new PO in new window. Set _kF_VendorID and capture $PO_ID. Switch to POLI layout. Import records from found Items. Replace _kF_PO_ID with $PO_ID Go to Related PO form view.
Newbies Pascal_82 Posted March 20, 2011 Author Newbies Posted March 20, 2011 Thanks for your help !! How do I capture ? Just a "Copy" ? Will I be able to add manually some items in the PO in the portal after ?
bcooney Posted March 21, 2011 Posted March 21, 2011 Here's a quick demo. You'd need Receipts or some way to close a PO to reduce QtyOnOrder. This demo's purpose is to illustrate how to import from a found set in the same file to create the PO Line Items. CreatePO.fp7.zip
Recommended Posts
This topic is 4996 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now