project QadFinancials > class BCashReport > method RecalculateInitializeGLLines

Description

Initialize the GLLines concerning the LC, TC and CC amounts.


Parameters


icCashReportGLRowidinputcharacter
icCashReportGLCurrencyViewinputcharacter
iiCashReportGLCurrency_IDinputinteger
oiReturnStatusoutputintegerReturn status of the method.


Internal usage


QadFinancials
method BCashReport.Recalculate


program code (program4/bcashreport.p)

/* Assign the error status to 'Unknown error' */
assign oiReturnStatus = -98.

/* Initialize GLLines. */
for each tCashReportGLLine where
         tCashReportGLLine.tc_Status               <> 'D':U                         and
         tCashReportGLLine.tc_ParentRowid           = icCashReportGLRowid           and
         tCashReportGLLine.CashReportGLLineCurrView = icCashReportGLCurrencyView    and
         tCashReportGLLine.Currency_ID              = iiCashReportGLCurrency_ID:

   assign tCashReportGLLine.CashReportGLLineLC = 0
          tCashReportGLLine.CashReportGLLineTC = 0
          tCashReportGLLine.CashReportGLLineCC = 0.
end.

/* If the procedure reaches its end correctly and no validation errors were encountered */
/* then assign the return status 'OK' */
if oiReturnStatus = -98 then assign oiReturnStatus = 0.