project BLF > class BRole > method CreateCustomTable0

Description

Initialize a new record in class table tCustomTable0.


Parameters


ic_ParentRowidinputcharacter= tCustomTable0.tc_ParentRowid
BRoleoutputdatasetclass dataset, containing only the newly initialized record
oiReturnStatusoutputintegererror status


program code (program/brole.p)

    assign oiReturnStatus = -98.

    empty temp-table t_sRole.
    empty temp-table t_sRoleResource.
    empty temp-table t_sTransString.
    empty temp-table t_sCustomTable0.
    empty temp-table t_sCustomTable1.
    empty temp-table t_sCustomTable2.
    create tCustomTable0.
    assign tCustomTable0.tc_Rowid  = dynamic-function("GetNumberForNew":U in {&TARGETPROCEDURE})
           tCustomTable0.tc_Status = "N":U.
    assign tCustomTable0.tc_ParentRowid = ic_ParentRowid.
    { includes/bfcrun.i
      &procedure  = "InitialValues"
      &parameters = "input 'CustomTable0':U,
                     output oiReturnStatus" }

    create t_sCustomTable0.
    raw-transfer tCustomTable0 to t_sCustomTable0.