2 Replies Latest reply on Dec 22, 2010 11:56 AM by AndyKandy

    Replace a field



      Replace a field



      I so new and I have a very easy question

      I need to modify a script in order to set a group of records

      The script uses a Go To related record to print a specific layout with a series of record that mach the selection

      however, I need to set a specific field of the series with a value to understand that I have printed these records

      someone can help me out

        • 1. Re: Replace a field

          Your own title nearly names the script step you can use to assign a value to a specified field for every record in the current found set.

          Use Replace Field Contents. You can use this step to assign a constant value, the results of a calculation (which can assign a different value to every record) or a serial number.

          Three cautions:

          1) If this file is hosted over a network, it's possible that another user may be editing one of these records. If so, record locking will prevent Replace Field Contents from modifying the record's data. You'll get an error message that this occurred, but the message won't tell you which record didn't get updated. Thus, Replace Field Contents should only be used in circumstances where you can be sure this can't happen or where you have some routine built in to handle the problem.

          2) Replace field contents can modify every record in a table. It's a good idea to make frequent back ups until you've confirmed that the script works exactly as intended. That way you can toss your file and try again if if you get a lot of records changed in a way you didn't expect.

          3) Make sure that you check for related records just before GTRR or the absence of an error code just after GTRR. If a script uses GTRR and there are no related records, the script continues to execute, but not on diffent layout specified in the GTRR and thus may modify a completely different group of records than intended.

          • 2. Re: Replace a field

            Yes is working

            Thank you