SAP Function Modules

CRIF_PT_INIT_MINIAPP SAP Function module







CRIF_PT_INIT_MINIAPP is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name CRIF_PT_INIT_MINIAPP into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: PTWAO_TIMEREC
Released Date: Not Released
Processing type: Remote-Enabled
remote enabled module settings


Pattern for FM CRIF_PT_INIT_MINIAPP - CRIF PT INIT MINIAPP





CALL FUNCTION 'CRIF_PT_INIT_MINIAPP' "
  EXPORTING
    webapp_debug_id =           " t77s0-semid
  IMPORTING
    ex_pernr =                  " p0105-pernr
  TABLES
    time_event_types =          " ptwao_s_tevgr
*   reasons =                   " ptwao_s_attab
    return =                    " bapiret2
*   internalorders =            " ptwao_s_inord
*   costcenters =               " ptwao_s_costc
*   objects =                   " ptwao_s_objid
*   wbs_elements =              " ptwao_s_wbsel
    .  "  CRIF_PT_INIT_MINIAPP

ABAP code example for Function Module CRIF_PT_INIT_MINIAPP





The ABAP code below is a full code listing to execute function module CRIF_PT_INIT_MINIAPP including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).

DATA:
ld_ex_pernr  TYPE P0105-PERNR ,
it_time_event_types  TYPE STANDARD TABLE OF PTWAO_S_TEVGR,"TABLES PARAM
wa_time_event_types  LIKE LINE OF it_time_event_types ,
it_reasons  TYPE STANDARD TABLE OF PTWAO_S_ATTAB,"TABLES PARAM
wa_reasons  LIKE LINE OF it_reasons ,
it_return  TYPE STANDARD TABLE OF BAPIRET2,"TABLES PARAM
wa_return  LIKE LINE OF it_return ,
it_internalorders  TYPE STANDARD TABLE OF PTWAO_S_INORD,"TABLES PARAM
wa_internalorders  LIKE LINE OF it_internalorders ,
it_costcenters  TYPE STANDARD TABLE OF PTWAO_S_COSTC,"TABLES PARAM
wa_costcenters  LIKE LINE OF it_costcenters ,
it_objects  TYPE STANDARD TABLE OF PTWAO_S_OBJID,"TABLES PARAM
wa_objects  LIKE LINE OF it_objects ,
it_wbs_elements  TYPE STANDARD TABLE OF PTWAO_S_WBSEL,"TABLES PARAM
wa_wbs_elements  LIKE LINE OF it_wbs_elements .


SELECT single SEMID
FROM T77S0
INTO @DATA(ld_webapp_debug_id).


"populate fields of struture and append to itab
append wa_time_event_types to it_time_event_types.

"populate fields of struture and append to itab
append wa_reasons to it_reasons.

"populate fields of struture and append to itab
append wa_return to it_return.

"populate fields of struture and append to itab
append wa_internalorders to it_internalorders.

"populate fields of struture and append to itab
append wa_costcenters to it_costcenters.

"populate fields of struture and append to itab
append wa_objects to it_objects.

"populate fields of struture and append to itab
append wa_wbs_elements to it_wbs_elements. . CALL FUNCTION 'CRIF_PT_INIT_MINIAPP' EXPORTING webapp_debug_id = ld_webapp_debug_id IMPORTING ex_pernr = ld_ex_pernr TABLES time_event_types = it_time_event_types * reasons = it_reasons return = it_return * internalorders = it_internalorders * costcenters = it_costcenters * objects = it_objects * wbs_elements = it_wbs_elements . " CRIF_PT_INIT_MINIAPP
IF SY-SUBRC EQ 0. "All OK ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_ex_pernr  TYPE P0105-PERNR ,
ld_webapp_debug_id  TYPE T77S0-SEMID ,
it_time_event_types  TYPE STANDARD TABLE OF PTWAO_S_TEVGR ,
wa_time_event_types  LIKE LINE OF it_time_event_types,
it_reasons  TYPE STANDARD TABLE OF PTWAO_S_ATTAB ,
wa_reasons  LIKE LINE OF it_reasons,
it_return  TYPE STANDARD TABLE OF BAPIRET2 ,
wa_return  LIKE LINE OF it_return,
it_internalorders  TYPE STANDARD TABLE OF PTWAO_S_INORD ,
wa_internalorders  LIKE LINE OF it_internalorders,
it_costcenters  TYPE STANDARD TABLE OF PTWAO_S_COSTC ,
wa_costcenters  LIKE LINE OF it_costcenters,
it_objects  TYPE STANDARD TABLE OF PTWAO_S_OBJID ,
wa_objects  LIKE LINE OF it_objects,
it_wbs_elements  TYPE STANDARD TABLE OF PTWAO_S_WBSEL ,
wa_wbs_elements  LIKE LINE OF it_wbs_elements.


SELECT single SEMID
FROM T77S0
INTO ld_webapp_debug_id.


"populate fields of struture and append to itab
append wa_time_event_types to it_time_event_types.

"populate fields of struture and append to itab
append wa_reasons to it_reasons.

"populate fields of struture and append to itab
append wa_return to it_return.

"populate fields of struture and append to itab
append wa_internalorders to it_internalorders.

"populate fields of struture and append to itab
append wa_costcenters to it_costcenters.

"populate fields of struture and append to itab
append wa_objects to it_objects.

"populate fields of struture and append to itab
append wa_wbs_elements to it_wbs_elements.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name CRIF_PT_INIT_MINIAPP or its description.