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: 

need to print report imediately

Former Member
0 Kudos
90

i need to print the report output immediately i am pasting some code which i am having problem , in job_open function module exporting parameters are gettting problem.

CALL FUNCTION 'GET_PRINT_PARAMETERS'

EXPORTING

mode = 'BATCH'

report = l_repid

IMPORTING

out_parameters = l_parms

valid = valid.

IF valid <> space.

CALL FUNCTION 'JOB_OPEN'

EXPORTING

jobname = my_job.

SUBMIT l_repid VIA JOB 'MY_JOB' NUMBER jobcount TO SAP-SPOOL WITHOUT

SPOOL DYNPRO SPOOL PARAMETERS l_parms.

CALL FUNCTION 'JOB_CLOSE'.

ENDIF.

*Sending the print parameters to this.

CALL FUNCTION 'GET_PRINT_PARAMETERS'

EXPORTING

destination = 'LP01'

IMPORTING

out_parameters = l_parms

valid = valid.

IF valid <> space.

NEW-PAGE PRINT ON PARAMETERS l_parms.

ENDIF.

1 REPLY 1

Former Member
0 Kudos
53

Hi!

*Sending the print parameters to this.

CALL FUNCTION 'GET_PRINT_PARAMETERS'

EXPORTING

destination = 'LP01'

immediately = 'X' "<<< add this line - immediate print

NEW_LIST_ID = 'X' "<<< add this line - new spool request

IMPORTING

out_parameters = l_parms

valid = valid.

Regards

Tamá