Skip to Content
0
Former Member
Jan 25, 2011 at 04:03 AM

Adding the fields on standard report

1010 Views

Hi EXperts,

Please guide me, i am new for modifiying the standard programs.

i want add the field custom field,i e pendding days.from iw59.

i copy the program to Z than i calculate the pendingdays.

that varible also append the final internal table.

but i cann't add the fieldcat,because there are not using manuallly.they are used as shown asbelow.

So please guide me any one how i can display the field.

CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'

EXPORTING

i_program_name = g_repid

i_internal_tabname = 'OBJECT_TAB'

i_structure_name = tabname

i_client_never_display = ' '

CHANGING

ct_fieldcat = g_fieldcat_tab[]

EXCEPTIONS

inconsistent_interface = 1

program_error = 2

OTHERS = 3.

END-ENHANCEMENT-SECTION.

$$-Start: CREATE_FIELDCAT_F14_01----


$$

ENHANCEMENT 1 DIMP_GENERAL_MIOLXF14. "active version

CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'

EXPORTING

i_program_name = g_repid

i_internal_tabname = 'OBJECT_TAB'

i_structure_name = tabname

i_client_never_display = ' '

  • INSERT BA-Project

i_bypassing_buffer = 'X'

  • END INSERT BA

CHANGING

ct_fieldcat = g_fieldcat_tab[]

EXCEPTIONS

inconsistent_interface = 1

program_error = 2

OTHERS = 3.

ENDENHANCEMENT.

CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'

EXPORTING

i_buffer_active = g_alv_buffer

i_callback_program = g_repid

i_callback_pf_status_set = g_form_set_pf_stat

  • I_CALLBACK_USER_COMMAND = ' '

  • I_STRUCTURE_NAME =

is_layout = g_layout

it_fieldcat = g_fieldcat_tab[]

  • it_excluding =

it_special_groups = g_fieldgroups_tab[]

it_sort = g_sortfields_tab[]

  • it_filter =

  • is_sel_hide =

i_default = g_n

  • i_save = g_variant_save

i_save = g_a

is_variant = g_variant

it_events = g_events_tab[]

it_event_exit = g_event_exit_tab[]

is_print = g_print

i_screen_start_column = g_screen_start_column

i_screen_start_line = g_screen_start_line

i_screen_end_column = g_screen_end_column

i_screen_end_line = g_screen_end_line

it_except_qinfo = gt_qinf

  • importing

  • e_exit_caused_by_caller =

TABLES

t_outtab = object_tab

EXCEPTIONS

program_error = 1

OTHERS = 2.

IF NOT sy-subrc IS INITIAL.

MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno

WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

ENDIF.

ELSE.

CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'

EXPORTING

i_buffer_active = g_alv_buffer

i_callback_program = g_repid

  • I_CALLBACK_PF_STATUS_SET = ' '

  • I_CALLBACK_USER_COMMAND = ' '

  • I_STRUCTURE_NAME =

is_layout = g_layout

it_fieldcat = g_fieldcat_tab[]

  • it_excluding =

it_special_groups = g_fieldgroups_tab[]

it_sort = g_sortfields_tab[]

  • it_filter =

  • is_sel_hide =

i_default = g_n

  • i_save = g_variant_save

i_save = g_a

is_variant = g_variant

it_events = g_events_tab[]

it_event_exit = g_event_exit_tab[]

is_print = g_print

i_screen_start_column = g_screen_start_column

i_screen_start_line = g_screen_start_line

i_screen_end_column = g_screen_end_column

i_screen_end_line = g_screen_end_line

it_except_qinfo = gt_qinf

  • importing

  • e_exit_caused_by_caller =

TABLES

t_outtab = object_tab

EXCEPTIONS

program_error = 1

OTHERS = 2.

IF NOT sy-subrc IS INITIAL.

MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno

WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

ENDIF.

Thanks advance