Hi all,
i've a Problem with a modification of an VC.
My vc has 3 views, and after creating or changing an entry, in every one of this three, the creator or changer need to be saved.
the event time is befoer saving (04).
i have create a report with a form add_user.
REPORT vc_prc_exits.
INCLUDE lsvcmcod.
TYPES: BEGIN OF ty_prc .
INCLUDE STRUCTURE t_prc.
INCLUDE STRUCTURE vimflagtab.
TYPES: END OF ty_prc.
DATA: gs_prc TYPE ty_prc.
*&---------------------------------------------------------------------*
FORM add_user.
DATA:
lv_error_flag TYPE vcl_flag_type.
DATA:
lt_prc TYPE TABLE OF /prego/t_prc.
IF vcl_last_view EQ 'V_PRC'.
PERFORM vcl_set_table_access_for_obj
USING
vcl_last_view
CHANGING
lv_error_flag.
IF lv_error_flag IS INITIAL.
CLEAR gs_prc.
LOOP AT <vcl_extract> INTO gs_prc.
CASE gs_prc-mark.
WHEN 'M'.
EXIT.
WHEN 'U'. "Eintrag wurde modifiziert.
gs_prc-aedat = sy-datum.
gs_prc-aenam = sy-uname.
WHEN 'D'. "Eintrag wurde gelöscht
WHEN 'Y'. "Eintrag wurde zunächst geändert und anschließend gelöscht
WHEN 'X'. "Eintrag wurde neu angelegt und anschließend gelöscht
WHEN 'N'. "Eintrag wurde neu angelegt
gs_prc-erdat = sy-datum.
gs_prc-ernam = sy-uname.
WHEN OTHERS. "<Leerzeichen>: Eintrag ist unmodifiziert*
ENDCASE.
ENDLOOP.
ENDIF.
ENDIF.
the problem is, i don't know, how to change <vcl_total>, tha my added data will be written to the database.
i'm trying this:
* PERFORM edit_view_entry IN PROGRAM (...) (i've look for a programm, that i can used, but it doesn't work.
* TABLES <vcl_extract>
* <vcl_total>
* <vcl_header>
* <vcl_namtab>
* <vcl_dpl_sellist>
*USING gs_prc 'UPD'.
could someone help me, please?
thank you and good bye
adalbert