AnsweredAssumed Answered

Need Script or Equation: GoTo "Previous Month"; "Last Record", etc.

Question asked by springer01 on Feb 10, 2018
Latest reply on Feb 13, 2018 by philmodjunk

My VISA acc't Layout records transactions summarized by Month in a Sub-summary Part (trailing). Four Fields match the data in the VISA statement: "Previous Balance", "Payments & Credits", "Purchases & Other Charges" and "New Balance."

The "Payments" are Credits and the "Purchases" are Debits.

The Layout is sorted by c_DateSort, the equation (below) provided by philmodjunk, because the VISA Statement starts each Month on the 5th and ends on the next Month's 4th.

To satisfy the "Previous Balance" a Script or Equation is needed, like: GoTo "previous Month", "last Record", Field "s_running_balance", copy and paste in the current Month's "Previous Balance" Field.

Each Record has the flwg Fields: n_ser_nbr, d_date, t_payee, t_category_t_memo, n_debit, n_credit, s_running_balance.

Sub-summary Part (leading):

Sub-summary_leading.png

Body:

Body.png

The Sub-summary Part (trailing) Fields are: VISA Statement Month of: c_DateSort (Month name); Previous Balance (to be determined); Payments & Credits: s_subtotal_credits; Purchases & Other Charges: s_subtotal_debits; and New Balance: s_running_balance.

Sub-summary_traiing.png

The cDateSort equation provided by philmodjunk,is:

Calculation   = Let ( [ dt = ( d_date) ;

dy = Day  ( dt ) ;

m = Month ( dt ) ] ;

 

Date ( m - ( dy < 5 ) ; 1 ;

Year ( dt ) )

) // let

Ergo, needed is the Script or Equation to satisfy the "Previous Balance" Field. Any help provided will be greatly appreciated.

Outcomes