Professional Documents
Culture Documents
endmethod. "handle_double_click
*&---------------------------------------------------------------------*
*& global definitions
*&---------------------------------------------------------------------*
data: g_custom_container type ref to cl_gui_custom_container,"container1
g_handler type ref to lcl_event_handler. "handler
* processing events
call method g_grid->list_processing_events
exporting
i_event_name = 'top_of_page'
i_dyndoc_id = dg_dyndoc_id.
"end }
* set editable cells to ready for input initially
call method g_grid->set_ready_for_input
exporting
i_ready_for_input = 1.
endform. "create_and_init_alv
*&---------------------------------------------------------------------*
*& form exclude_tb_functions
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
* -->pt_exclude text
*----------------------------------------------------------------------*
form exclude_tb_functions changing pt_exclude type ui_functions.
* only allow to change data not to create new entries (exclude
* generic functions).
data ls_exclude type ui_func.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_copy_row.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_delete_row.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_append_row.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_insert_row.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_move_row.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_copy.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_cut.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_paste.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_paste_new_row.
append ls_exclude to pt_exclude.
ls_exclude = cl_gui_alv_grid=>mc_fc_loc_undo.
append ls_exclude to pt_exclude.
endform. " exclude_tb_functions
*&---------------------------------------------------------------------*
*& form build_fieldcat
*&---------------------------------------------------------------------*
* fieldcatalog
*----------------------------------------------------------------------*
form build_fieldcat .
data: l_pos type i.
l_pos = l_pos + 1.
x_fieldcat-scrtext_m = 'delivery'(024).
x_fieldcat-fieldname = 'vbeln'.
x_fieldcat-tabname = 'it_final'.
x_fieldcat-col_pos = l_pos.
x_fieldcat-no_zero = 'x'.
x_fieldcat-outputlen = '10'.
x_fieldcat-hotspot = 'x'.
x_fieldcat-scrtext_m = 'item'(025).
x_fieldcat-fieldname = 'posnr'.
x_fieldcat-tabname = 'it_final'.
x_fieldcat-col_pos = l_pos.
x_fieldcat-outputlen = '5'.
append x_fieldcat to it_fieldcat.
clear x_fieldcat.
l_pos = l_pos + 1.
x_fieldcat-scrtext_m = 'drop'(025).
x_fieldcat-fieldname = 'drop'.
x_fieldcat-tabname = 'it_final'.
x_fieldcat-col_pos = l_pos.
x_fieldcat-outputlen = '5'.
x_fieldcat-edit = 'x'.
x_fieldcat-drdn_hndl = '1'.
x_fieldcat-drdn_alias = 'x'.
append x_fieldcat to it_fieldcat.
clear x_fieldcat.
*&---------------------------------------------------------------------*
*& form set_drdn_table
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
form set_drdn_table.
clear : dl_text.
* move program id
concatenate 'program name :' sy-repid
into dl_text separated by space.
* add program name to document
perform add_text using dl_text.
* add new-line
call method dg_dyndoc_id->new_line.
clear : dl_text.
clear : dl_text.
* move user id
concatenate 'user id :' sy-uname into dl_text separated by space
.
* add user id to document
perform add_text using dl_text.
* add new-line
call method dg_dyndoc_id->new_line.
clear : dl_text.
* move client
concatenate 'client :' sy-mandt into dl_text separated by space.
* add client to document
perform add_text using dl_text.
* add new-line
call method dg_dyndoc_id->new_line.
clear : dl_text.
* move date
write sy-datum to dl_text.
concatenate 'date :' dl_text into dl_text separated by space.
* add date to document
perform add_text using dl_text.
* add new-line
call method dg_dyndoc_id->new_line.
clear : dl_text.
* move time
write sy-uzeit to dl_text.
concatenate 'time :' dl_text into dl_text separated by space.
* add time to document
perform add_text using dl_text.
* add new-line
call method dg_dyndoc_id->new_line.
* populating data to html control
perform html.