Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Adding parameter to standard report

former_member188321
Contributor
0 Kudos

Hi Experts,

I need to enhance a CRM report and add custom selection screen parameters to this. The implicit enhancement is only at end of report . Also, there is an include used in that report, but that include is used in many other reports so I would refrain from enhancing that.

What is the other way to add selection screen parameters to this report?

Regards,

1 ACCEPTED SOLUTION

former_member188321
Contributor
0 Kudos

Closing the thread as only option is to enhance the include of the report to add parameter. Also enhance underlying classes for logic.

6 REPLIES 6

rosenberg_eitan
Active Contributor
0 Kudos

Hi,

I do not know if this is applicable in your case .

Using cl_salv_bs_runtime_info you get the data from the called program ALV  and continue

from there .

Also see:

Code fragment:

cl_salv_bs_runtime_info=>set(

    EXPORTING display = abap_false

      metadata = abap_true

      data     = abap_true ) .

  SUBMIT rmsrvr10

    WITH srvpos  IN srvpos

    WITH p_banf  EQ p_banf

    WITH p_anfr  EQ p_anfr

    WITH p_best  EQ p_best

    WITH p_kontr EQ p_kontr

    WITH p_erfbl EQ p_erfbl

    WITH werks   IN r_werks

         AND RETURN .

  DATA: it_r_data TYPE REF TO data.

  FIELD-SYMBOLS <it_r_data> TYPE ANY TABLE.

  DATA: metadata TYPE cl_salv_bs_runtime_info=>s_type_metadata .

  TRY.

      cl_salv_bs_runtime_info=>get_data_ref(

       IMPORTING r_data = it_r_data ) .

      ASSIGN it_r_data->* TO <it_r_data> .

      metadata = cl_salv_bs_runtime_info=>get_metadata( ) .

    CATCH cx_salv_bs_sc_runtime_info.

      MESSAGE 'Unable to retrieve ALV data' TYPE 'E'.

  ENDTRY.

  cl_salv_bs_runtime_info=>clear_all( ) .

Regards .

0 Kudos

Hi Eitan,

This report is used by standard functionality for Mass change in Background. Will the proposal fit for reports scheduled in background?

Regards,

0 Kudos

Hi,

Checking.....

Regards.

0 Kudos

Hi,

This is for reporting ONLY.

Yes it is working .

Full sample program code included ( Z_R_EITAN_TEST_08_18 ) .

This program use SAP program RMSRVR10 .

I add plant to selection screen and output ALV .

There was no harm done to RMSRVR10 in this process....

Regards .

rosenberg_eitan
Active Contributor
0 Kudos

Hi,

This technic is not for Mass change in Background .

Regards.

former_member188321
Contributor
0 Kudos

Closing the thread as only option is to enhance the include of the report to add parameter. Also enhance underlying classes for logic.