Quantcast
Channel: SCN : Blog List - All Communities
Viewing all articles
Browse latest Browse all 2548

Output Type driven forms to Application Server

$
0
0

Requirement - The business may need a PDF output of any forms to be available for the legacy systems, So we may end up in copying the standard driver program and addition of logic to save the pdf output in application server.

 

Solution - SAP has already provided a program RSNAST0D to process Generic Output type. Which generates a spool number and from this we can use the function modules CONVERT_OTFSPOOLJOB_2_PDF or CONVERT_ABAPSPOOLJOB_2_PDF based on the Object Type of the spool to get the PDF content and write this content to the file placed in the application server

 

Selection Screen of the program RSNAST0D

 

Based on the selection criteria, user can enter any Application, Output Type to get the list of output available for processing, Select the row and issue the output will generate the spool for you.

 

Using this spool number, further we can make use of the explicit enhancement point to write the additional logic to retrieve the PDF contents using the above mentioned function modules and convert the PDF content to BINARY format.

 

Following screenshot shows the conversion of PDF content to BINARY format and then transferring the data to file.

 

Necessary Actions to reuse the functionality

Since the Implementation of the enhancement spot ES_RSNAST00, triggers all the time when an output is issued using any other transactions. To restrict this you can check whether SY-CPROG is always RSNAST0D or check the SY-TCODE assigned to program RSNAST0D.

 

Note: If there is a requirement to save PDF output to Application server whenever an output type 'XXXX' is issued, then use the static attribute flag of the class to mark as 'TRUE' in the Print program or driver program or the interface and then use this flag to trigger the Implementation of the enhancement spot ES_RSNAST00.


Viewing all articles
Browse latest Browse all 2548

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>