4 Replies Latest reply on Apr 13, 2013 1:46 AM by Fred(CH)

    Problem with Delete Portal Row Script



      Problem with Delete Portal Row Script


           I have an issue with a script that contains the delete portal row script.

           If I create a new record in the portal, I cannot delete the portal row.  I can delete portal rows using the script for records that have previously existed but I cannot delete newly created records via the portal.  I've tried refreshing the screen but it still doesn't work.  The only way I can get the delete the portal row script to work is to close the file and re-open it.  Then I can delete the portal row.

           We are using Filemaker 10 and Filemaker Server 10.



        • 1. Re: Problem with Delete Portal Row Script

               Your newly created record has not yet been "committed". It can be reverted, but not deleted until you commit the record. It's like you are trying to delete a word processor file from your computer when you still have it open for the first time with your word processor program. You can close the file without saving (rever) but you can't yet delete it because there's no file on your hard drive yet that you can delete.

               Your script may need to do a commit records step first, but be careful, that destroys the "focus" on the portal row so you have to save the the current portal row number in a variable, commit the record and then use go to portal row to return to the record before it can delete it.

          • 2. Re: Problem with Delete Portal Row Script

                 Ok, makes sense to me.  Thanks

            • 3. Re: Problem with Delete Portal Row Script

                   Hi there,

              Boss : Sorry but i must to desagree (please, don't fire me smiley).

                   In terms of validation, a portal's row is almost managed like a field. You will notice it If you do theses 2 tests :

                   1 Open a Record with both standard fields and a portal

                   2 Enter data in the fields and add a new row with data on it

                   3a Then, Try to revert the record,

                   Result : Your modifications are canceled and of course, no new row on your portal.


                   3b Delete Portal Row (but remember : you did'nt commit the record)

                   Result : Your row is even canceled. However, if you try then to Revert the whole record, your row will no reappear because, as you said previously, it was not committed.

              Carla :

                   Just a detail : you made a mistake when you wanted to define Phil's answer as the better and defined your own last comment as is. Bad girl...wink

              All :

                   I noticed this bug on previous version of FM 12 but only on hosted files. But never encountered on v12 yet.

                   I arrived at this post today because i wanted to "sell" a v12 to my customer who has many times encountered this issue and i was searching a clear issue report and a clear confirmation that the bug will no longer live in v12.

                   If i find it, see you soon on this post.

                   Bye, Fred

              • 4. Re: Problem with Delete Portal Row Script

                     Oulah... Arrgh... [Self-Censored Explicit Content]

                     So i found this thead here :

                Delete portal row issue

                     I am really afraid and a bit disappointed because it seems the bug is still living on v12 environment.

                     Bye, Fred