on 07-16-2008 11:31 AM
Hi All,
Is it possible to run our general ABAP report in our WDA.
If yes how can i move....
Thanks & regards,
Ravi
Hello,
You can call your report using the SUBMIT command to call it like a job. Follow an example on how to do this (from ABAP Help).
DATA: number TYPE tbtcjob-jobcount,
name TYPE tbtcjob-jobname VALUE 'JOB_TEST',
print_parameters TYPE pri_params.
...
CALL FUNCTION 'JOB_OPEN'
EXPORTING
jobname = name
IMPORTING
jobcount = number
EXCEPTIONS
cant_create_job = 1
invalid_job_data = 2
jobname_missing = 3
OTHERS = 4.
IF sy-subrc = 0.
SUBMIT submitable TO SAP-SPOOL
SPOOL PARAMETERS print_parameters
WITHOUT SPOOL DYNPRO
VIA JOB name NUMBER number
AND RETURN.
IF sy-subrc = 0.
CALL FUNCTION 'JOB_CLOSE'
EXPORTING
jobcount = number
jobname = name
strtimmed = 'X'
EXCEPTIONS
cant_start_immediate = 1
invalid_startdate = 2
jobname_missing = 3
job_close_failed = 4
job_nosteps = 5
job_notex = 6
lock_failed = 7
OTHERS = 8.
IF sy-subrc <> 0.
...
ENDIF.
ENDIF.
ENDIF.
But this is only usefull if this report only process data and don't show data on screen, because this data can´t be showed in the web dynpro via write commands like described in the threads before.
Regards.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
> Hello,
>
> You can call your report using the SUBMIT command to call it like a job. Follow an example on how to do this (from ABAP Help).
> But this is only usefull if this report only process data and don't show data on screen, because this data can´t be showed in the web dynpro via write commands like described in the threads before.
>
> Regards.
Actually with a few changes you are close to a solution here. There is way to get the output of the report and convert it to HTML. You will need to have a little wrapper application around your report. You will have to run this wrapper as a background job or via RFC (pointing to destination NONE). Here is a sample:
*----------------------------------------------------------------------*
* SELECTION SCREEN LAYOUT *
*----------------------------------------------------------------------*
selection-screen begin of block two with frame title text-002.
parameter: prog like sy-repid.
parameter: vari1 like raldb-variant.
selection-screen end of block two.
.....Other Processing....
submit (prog) and return
exporting list to memory
using selection-set vari1.
call function 'LIST_FROM_MEMORY'
tables
listobject = itab
exceptions
not_found = 1.
if sy-subrc ne 0.
leave program.
endif.
call function 'WWW_HTML_FROM_LISTOBJECT'
exporting
* REPORT_NAME =
template_name = 'WEBREPORTING_REPORT'
tables
html = html_tab
listobject = itab.
Once the data is converted into HTML it is more usable from WD. You can't really display it directly within WD, but you could push it out as a file attachment from WD using cl_wd_runtime_services=>attach_file_to_response.
This is a lot of work and I still think it might be easier to fire a linkToURL or Exit Plug and navigate to the ITS/WebGUI.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.