1 Reply Latest reply on Mar 1, 2010 12:42 PM by philmodjunk

    Delete Portal Row with external file's table

    Ender

      Summary

      Delete Portal Row with external file's table

      Description of the issue

      When the user's privilege set is set to not allow deletion of records in the child table (set in the Records privileges), but the script is set to "Run script with full access privileges", a Delete Portal Row script step should delete the record in the child table.  This works correctly when the child table is based in the same file as the interface, but does not seem to work when the child table is in a different file (the error message: "Your access privileges do not allow you to perform this action" comes up.) Confirmed this in FM8.5, FM9, & FM10v3 on Mac OS 10.5.  

        • 1. Re: Delete Portal Row with external file's table
          philmodjunk

          When I first encountered this, I thought it was a bug too until I read this in the help file:

           

            •
          The Run script with full access privileges feature only functions in the file in which the script is defined. This command will not override access restrictions on external files. For example, a script to delete records in File A that has the Run script with full access privileges option enabled will not delete records in an access-restricted external file File B.

           

          To delete the records in the external file, you have to run a "full access" delete script defined in the external file.

           

          Something like this:

          Perform a script in the external file--passing data in the script parameter that uniquely identifies the record to be deleted.

          Select the current window.

           

          In the external file the script (Select run with full access privileges on this script):

          Uses Get ( ScriptParamater ) to perform a find that finds the portal record you want to delete

          Deletes the record.