5 Replies Latest reply on Oct 11, 2012 10:06 AM by philmodjunk

    New Record in Portal

    spike

      Title

      New Record in Portal

      Post

           Hi everyone i just want to ask if there is a way of adding new record in portal? i have 4 portals in one layout and i just want to add a new record in in one portal but the other portal will not be affected.. thanks in advanced

        • 1. Re: New Record in Portal
          philmodjunk

               Manually or in a script?

               If you enable "allow creation of records via this relationship" for the portal's table in the relationship needed for this portal, simply entering data in the blank "add" row of the portal will create a related record in the portal's table with all the match field data correctly set up so that it will appear in your portal.

               But adding a new record to a portal can also be done with a script.

               Set variable [$ID ; value: Layouttable::matchfield] --->specify the field that serves as the match field in the relationship on which this portal is based.
               Freeze Window
               Go to Layout [//select layout based on portal's table]
               New Record/Request
               Set Field [PortalTable::Matchfield ; $ID]--->specify the match field in the portal's table
               Go To Layout [original layout]

          • 2. Re: New Record in Portal
            spike

                 i try the sript but still the same the new record will clear all the portal..  for example i have master table and 3 child table connected to each other. i have one layout with 3 portal that connected to the 3 table with 5 record.. im trying to insert new record in portal one but the 2 portal will not be affected.. i dont know if this is applicable to filemaker.. sorry for the grammar i hope you understand.. thanks for the reply..

            • 3. Re: New Record in Portal
              philmodjunk

                   Sorry, but I don't understand what you mean by:

                   

                        i try the sript but still the same the new record will clear all the portal..

                   Unless the portals refer to the same data source table, using this script to create a new record in one should not affect what appears in any of the others.

              • 4. Re: New Record in Portal
                spike

                     sorry about that but im trying to do is like in the screenshot there is 5 portal in one layout.. if i click the new type button in portal 1 it will insert new record and goto first field which is desc. but the other portal still the same..

                • 5. Re: New Record in Portal
                  philmodjunk

                       Why should it change what is shown in any other portal?

                       Please keep in mind that I have no idea what relationships or possible portal filters you may have used in setting this up.