It is a very common requirement to have the print output from smartforms or sap scripts saved as a local PDF file in the front end.
The different ways in which this can be accomplished are :-
Create a spool request for the print and use the report RSTXPDFT4 to save its content as a PDF file in the frontend.
Use ABAP coding to obtain the OTF data of the print and use Function modules CONVERT_OTF_2_PDF, GUI_DOWNLOAD (or OOPs Front end services) to convert and save the OTF data as a PDF file in the frontend system.
Configure a PDF printer output device in SPAD and maintain corresponding FILE printer in the front end systems. Print outputs can be routed to this output device for saving the print output as PDF file in the frontend system.
In this document we will be dwelving into the third option mentioned above which is the simplest way of meeting the requirement.
SAP notes associated with this option are :-
317851 : Creating PDF format via spooler in 4.6C/4.6B/4.5B
576973 : Creating a file printer on a Windows PC
323736 : Restrictions with "PDF print" through spooler
What is a FILE printer: Printers that use the FILE port(instead of LPT1, COM1 etc) can be added to the frontend system. These printers can be used for saving the print output as a local file. Click the "Add printer" task in the "Printers and Faxes" folder to start the Add printer wizard and add a new FILE printer as per the screenshots below: