12 Replies Latest reply on May 26, 2014 7:31 AM by Phyre

    Copy a multiple Record to another Record in Portal Row

    Phyre

      Title

      Copy a multiple Record to another Record in Portal Row

      Post

           How will I copy a field to another table portal row?
            
           My data go this way.
            
           I have a table of ITEM TABLE, PURCHASE  TABLE And BALANCE TABLE. 
           <ITEM>
           Field:  ItemName
           Field: Quantity
           Field: Price
            
           <Purchase> (Inside this table I have a portal row from <Balance Table> where I want to aste my record copy from Item)
           <Balance>
           Field:  ItemName
           Field: Quantity
           Field: Price
            
           The problem is I dont know what script steps to use. I try this scrips steps but only the itemname has shown
            
           (1) Script steps
           Set Variable {$ItemName; Value:;Item;ItemName}
           Go to Layout {"Purchase Item"Purchase}
           Go to Portal Row {Select First}
           Set Field {Balance::ItemName}
           Go to Record/Request/Page {First}
            
           (2) Script Steps
           Set Field {Item::ItemName}
           Copy {Select; Item::ItemName}
           Go to Layout {"Purchase Item"Purchase}
           Go to Portal Row {Select First}
           Paste {Select: Balance:;ItemName
           Go to Record/Request/Page {Next:Exit after last}
            
            

        • 1. Re: Copy a multiple Record to another Record in Portal Row
          Phyre

               This is my relationship I used And im using filemaker pro advance 13. 

          • 2. Re: Copy a multiple Record to another Record in Portal Row
            Phyre

                 Another Question How will I make this in script (#) or (Simplify) and what that mean for? I just saw it from the other users script steps?

                  

                  

            • 3. Re: Copy a multiple Record to another Record in Portal Row
              philmodjunk

                   I don't see a need for any scripts here from what you have described.

                   Your have these relationships and tables:

                   Purchases----<Balance>-----Item

                   Purchases::RecordID = Balance::PurchaseIDFK
                   Item::RecordID = Balance::ItemIDFK

                   There is no need to change your table names, but if you look at the Invoices Starter solution that comes with FileMaker, you'll find the same tables and relationships but with different names. You may want to examine that starter solution as an example of how this can be set up. In the starter solution, you'll find these tables/relationships:

                   Invoices----<InvoiceData>-------Products

                   In your portal to Balance, format the ItemIDFK field with a drop down list or popup menu of values using RecordID as the first field and an Item Name or Item Description field as the second field. You'll use the name or description to select a product and the value list will enter the appropriate ID number to link it to a record in Products.

                   Other fields in the Balance table, such as a field for the unit price would use an auto-enter field option such as the looked up value option to copy the current unit price from the Item table. You can either set up a description field in Balance that also looks up the Description from the matching record in the Item table or you can simply add the Description field from Items to your portal row.

                   All of this takes place without any scripting at all.

              • 4. Re: Copy a multiple Record to another Record in Portal Row
                Phyre

                     Thanks Phil. 

                     My intention of making a script steps is to make my page automation. From the Item Data to my Purchase with a selection box. I already got the script steps and it is now working fine. ;) Thanks a lot.

                      

                     One thing I cannot get is the "#" or "Simplify" How will I get i or use it in script and what is the value of the # sign ;) Curios

                • 5. Re: Copy a multiple Record to another Record in Portal Row
                  philmodjunk

                       Yes, but I don't see anything here to automate with a script as this can take place automatically and without any scripting to accomplish it.

                       

                            One thing I cannot get is the "#" or "Simplify" How will I get i or use it in script and what is the value of the # sign

                       I do not understand what you mean by that question.

                  • 6. Re: Copy a multiple Record to another Record in Portal Row
                    Phyre

                         Ok I will explain. ;)

                         In my Item Table I have a layout called canvass Item which is I sorted it by supplier so I can compare the price of each items by supplier's price.

                          

                    • 7. Re: Copy a multiple Record to another Record in Portal Row
                      Phyre

                           When you check the box, the selected Item that has been check will go directly to the portal in the Purchasing Table as a new record.

                           So the automation using script will do that way.

                           From the Item table in canvass Layout will write also in balance portal on Purchase Table.

                           What is the best way to do it?

                      • 8. Re: Copy a multiple Record to another Record in Portal Row
                        Phyre

                             This is what I mean by the # sign or the (Specify)

                             Sorry not "Simplify" but "Specify"

                        • 9. Re: Copy a multiple Record to another Record in Portal Row
                          philmodjunk

                               Script steps that start with # are simply comment lines. You can delete them and the function of your script will not change. They are a way for the person creating the script to add "notes" explaining the function of the script, or perhaps to make the script easier to read by adding a blank line to separate key sections of the script.

                               The "specify" dialog is what you would use to add text as a comment to that line.

                          • 10. Re: Copy a multiple Record to another Record in Portal Row
                            philmodjunk

                                 As far as your "automation" is concerned, I still can't quite understand your current design.

                                 

                                      In my Item Table I have a layout called canvass Item

                                 I think you mean that you have a layout called "canvass item" based on the Item table. Or do you mean that you have a portal to the Item table on your "canvass item" table.

                                 

                                      When you check the box, the selected Item that has been check will go directly to the portal in the Purchasing Table as a new record.

                                 What exactly do you mean by "portal in the purchasing table"? Is this a portal based on the purchasing table or do you mean something else?

                            • 11. Re: Copy a multiple Record to another Record in Portal Row
                              Phyre

                                   Ahh ic  I understand it now about the specify....

                                    

                                    

                                   The portal I mean is a portal base on the purchasing table. and yes Canvass Item based on Item Table. I don't have a canvass Item Table only Layout from Item Table or based on the Item table.

                                    

                                   Sorry I don't know how to explain it properly ;) Even the table occurrences and table something I don't get it exactly. ;) still I am a novice in this software ;)

                              • 12. Re: Copy a multiple Record to another Record in Portal Row
                                Phyre

                                     Thanksfor the explaination