project QadFinancials > class BMfgAccountPayableCtrl > method Createapc_ctrl

Description

Initialize a new record in class table tapc_ctrl.


Parameters


ic_ParentRowidinputcharacter= tapc_ctrl.tc_ParentRowid
BMfgAccountPayableCtrloutputdatasetclass dataset, containing only the newly initialized record
oiReturnStatusoutputintegererror status


program code (program/bmfgaccountpayablectrl.p)

    assign oiReturnStatus = -98.

    empty temp-table t_sapc_ctrl.
    empty temp-table t_sCustomTable0.
    empty temp-table t_sCustomTable1.
    empty temp-table t_sCustomTable2.
    create tapc_ctrl.
    assign tapc_ctrl.tc_Rowid  = dynamic-function("GetNumberForNew":U in {&TARGETPROCEDURE})
           tapc_ctrl.tc_Status = "N":U.
    { includes/bfcrun.i
      &procedure  = "InitialValues"
      &parameters = "input 'apc_ctrl':U,
                     output oiReturnStatus" }

    create t_sapc_ctrl.
    raw-transfer tapc_ctrl to t_sapc_ctrl.