Creating Adobe PDF forms in the WebUI of the SAP CRM

The SAP CRM system is in print form in contrast to other SAP systems, such as SAP EWM, currently exclusively on the printing of forms aligned with Smart Forms. In Customizing you can in the SAP CRM standard only forms and methods for printing of smart deposit forms.

Requirement

If you want also in SAP Adobe forms rather than by smart forms use, then are to perform the following tasks

  • Instead of a smart forms must be created an Adobe form in the method stored in Customizing.
  • The generated form in OTF format to the method for the print screen to pass is to display the form in the WebUI.

The following tutorial explains how to use the SAP CRM forms an Adobe form can generate.

CRM a service operation as a ticket is recorded in the SAP. The ticket is completed, a final report is delivered the customer. The final report should be created as a PDF form using the tools of the SAP Adobe forms. Pressure as well as a print screen of the form in the SAP CRM WebUI should be possible.


In Customizing for looking for the class, which represents the form printout in the actions to the operation. In our case, this was the class CL_DOC_PROCESSING_CRM_ORDER method CRM_SRVORDER_EXEC_SMART_FORM.

Now copy the class CL_DOC_PROCESSING_CRM_ORDER in a Z-class or derived your own Z class as a subclass of the superclass CL_DOC_PROCESSING_CRM_ORDER. Then copy method CRM_SRVORDER_EXEC_SMART_FORM in method CRM_SRVORDER_EXEC_PDF_FORM.


In the function module Z_FRM_PRINT_FINAL_REPORT the coding is accommodated well to the Adobe form (PDF form) to create. The interface is 1: 1 from the interface to the smart taken shape from the CRM_SRVORDER_EXEC_SMART_FORM method.

It is important that when creating the print screen is from JOB_OPEN parameter GETPDF = X is used.

The function module is in method CRM_SRVORDER_EXEC_PDF_FORM where built, where else the creation of smart forms is triggered. The coding for the creation of the smart forms is removed or commented out.

CRM WebUI the function module is used to display the Adobe forms in SAP CONVERT_PDF, where the form in OTF format to PDF is cast. Because we get the Adobe form already as a finished PDF file, the PDF file must be prepared, that the function module CONVERT_PDF as a finished PDF file identifies the file already and not converted. Otherwise you get an error message in the SAP CRM WebUI.

The PDF file as a binary object into an internal table of the format is transformed into routine CONVERT_PDF_2_OTF ITCOO.

The Adobe form displays now correctly CRM WebUI in the print view display in the SAP.

More information

SAP forms at a fixed price

SAP form development

Special topics on SAP Forms