cancel
Showing results for 
Search instead for 
Did you mean: 

Calling an existing ALV report in WD4A

Former Member
0 Kudos

Im going to try to call an existing ALV report using WD4A.

Was wondering if anybody has used the "SUBMIT <report> EXPORTING LIST TO MEMORY" option to get the results table, then after IMPORTING from memory, display this in ALV in Webdynpro abap?

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

I was able to acomplish the following way...

My WD4A component has an assistance class, has a method fetch_results, in that method, I pass my selection criteria which calls a function.

The function does this...


  SUBMIT  REPORTXYZ
  USING SELECTION-SET lv_variant 
  AND RETURN
    WITH pnppernr IN pnppernr
    WITH pnpbegps EQ act_begda
    WITH pnpendps EQ act_endda
    WITH pnpbegda EQ act_begda
    WITH pnpendda EQ act_endda
    WITH pnptimed EQ blank
    WITH p_layout EQ '/MGR SEP'
    WITH p_portal EQ 'X'.

My p_portal parameter is a flag that REPORTXYZ will use to export the it_output to memory.

I then import that table to the function module which returns to WD4A alv.


  IMPORT zit_output TO tbl_output FROM MEMORY ID
    lv_flag.

ChrisPaine
Active Contributor
0 Kudos

K,

I've done this in the past to provide a simple way to have both backend and portal based views of the same reports. (was in WDJ not WDA). In the end I decided that it wasn't a good solution.

Now all reports I build, I build them in a MVC design - and reuse the model in my WDA (or more usually POWL) implementation of the same report.

Chris