Skip to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

script new record creation and also sum data

Featured Replies

I have made a test file for myself to work out some scripting which I want to include in a larger budget accounting file I want to make.

The file has one table 'main', with the fields

budget category [indexed]

transaction

transaction date

transaction month [calc, indexed]

transaction year [calc, indexed]

and an occurrence of the table 'main' called 'main for scripted total'

related to the 'main' table by budget category, transaction month and transaction year

What I would like to do, ultimately, if I can figure out how to do it, is script the creation of new records and individual budget category totals and subtotals. I want to set these fields so the data is 'permanent' and so can be used elsewhere and also gives you a progressive set of totals to see as records are created.

the present script is :) create new record and set monthly budget category total

Goto layout ["main' main]

New record/request/

Pause/resume script

#fill out data here

Set field[main::transaction month total; Sum(main for scripted total::transaction)]

What happens is, for the first record in a month/year for a budget category, the transaction month total is empty, and the 'transaction' data entered for this record is not summed with future records. When a second, and subsequent records for a particular budget category and particular month/year, the script works as desired, the field is set and the total increases record by record.

My question is how do I properly setup and script the data for the 'first' record of a month/year, and in this case, have its data sum with subsequent records?

Help much appreciated

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.