‎2008 Aug 22 9:00 AM
Hi all,
I want to print an internal table data without displaying it via ALV. That is when clicked on a button, printing should be started.
How can I do that?
Thanks a lot.
Deniz.
‎2008 Aug 22 9:04 AM
1) Create job
2) Submit the ALV output in back gourd with print parameters, you can get the print.
Regards,
Sadasiva.
‎2008 Aug 22 9:05 AM
‎2008 Aug 22 9:05 AM
Hi Deniz,
Go for the following links:
[http://help.sap.com/search/highlightContent.jsp]
[http://help.sap.com/search/highlightContent.jsp]
Thnks.
‎2008 Aug 22 9:17 AM
Hi,
Check the following code this is exactly what you need I guess....
FM to generate spool number for the internal table wt_final_prnt.
CALL FUNCTION 'RSPO_SX_OUTPUT_TEXTDATA'
EXPORTING
name = gv_name
dest = gv_dest
rows = gv_rows
startrow = gv_startrow
pages = gv_pages
rqtitle = 'Z9CS - STD Search Results'
rqcopies = gv_rqcopies
rqowner = gv_rqowner
immediately = gv_immediate
IMPORTING
rqid = gv_rqid
TABLES
text_data = wt_final_prnt
EXCEPTIONS
OTHERS = 1.
CLEAR : wa_final_prnt, wt_final_prnt[].
FM to set the print attributes.
CALL FUNCTION 'GET_PRINT_PARAMETERS'
IMPORTING
out_parameters = wv_pripar
out_archive_parameters = wv_arcpar
valid = wv_val
EXCEPTIONS
archive_info_not_found = 1
invalid_print_params = 2
invalid_archive_params = 3
OTHERS = 4.
FM to submit to the printer
CALL FUNCTION 'RSPO_OUTPUT_SPOOL_REQUEST'
EXPORTING
spool_request_id = gv_rqid.
Regards,
Ram.