[BRF+ New Output Management]: Use DDIC Interface based Regular Custom Adobe Form – Handle ‘Spool request could not be found APOC_OR_MESSAGES 145’
For last few weeks, I was working on a requirement which required custom Adobe form for standard GR label through NACE but later, we had to opt for new BRF+ O/P management. The ideal approach is to use fragmented adobe form, but the number of fields were not there in standard service interface. So, we opted for DDIC interface option available in ‘Assign Form Templates’.
Challenge: To achieve this requirement, I had faced couple challenges:
- Spool request could not be found – APOC_OR_MESSAGES (145): Discussed in this blog.
- Dump – /BOBF/CX_FRW_FATAL – CLASS CL_APOC_OR_A_ITEM_GET_DOCUMENT: Create a Z* Driver program for the form individually and check the issue there – for my case, ADS Configuration was the issue, handled by me and basis tech guy.
- Bar code center alignment: Centre Alignment of BARCODE blog.
In this blog post we will cover the steps to print GR Label and handle Spool request could not be found – APOC_OR_MESSAGES (145).
- Firstly, get the name of the standard program – subroutine (Form routine) that you would be triggered in the back-end from the business process. You can later, choose any other sub-routine as well, if that one has better parameters as per your requirement. Make sure the sub-routine you are choosing to have *PDF or ADOBE* naming pattern to have the FP_JOB_OPEN/CLOSE else you must manually change the printout subroutine.
In my case, I have used Program – SAPM07DR, Routine – ENTRY_WE03_PDF.
- Create an executable report ZAB_IM_SAPM07DR replicating subroutine-pool SAPM07DR, includes ZIN_IM_M07DRTOP, ZIN_IM_M07DRSON_PDF from M07DRTOP, M07DRSON_PDF resp. and replace the std. includes with them in program ZAB_IM_SAPM07DR.
- Go to SFP, create a DDIC interface as per the parameters exported in sub-routine, handle required processing logic and create the required layout in ADOBE form to the interface.
- Point of solution: In subroutine FORM_OPEN_PDF, just before FP_JOB_OPEN – handle the output parameters as below, as per SAP KBA 3016791 – Error ‘Spool request could not be found.’:
gs_outputparams-getpdf = abap_false. gs_outputparams-reqnew = abap_true. gs_outputparams-covtitle = nast-tdcovtitle. gs_outputparams-nodialog = abap_true. gs_outputparams-preview = abap_false.
Activate the program.
- Share the name to functional or manage it in SPRO.
- Application Area: ‘Cross-Application Components’
- Sub Application Area: ‘Output Control’
- Select the configuration step ‘Assign Form Templates’ (SSCUI 102313)
- Application Object Type – GOODS_MOVEMENT
- Output Type – GOODS_RECEIPT_LABEL
- Form type – 2 – Output Forms (DDIC Interface)
- Form Template ID – ZAF_IM_GR_LABEL
- Program – ZAB_IM_SAPM07DR
- Routine – ENTRY_WE03_PDF
(Don’t forget to transport the config data with customizing transport in testing client – Tcode SCC1).
- Now functional will go to transaction OPD or below process, that will trigger Fiori launchpad.
And edit entry for the configured form under ‘Form Template’ for Rules for ‘GOODS_MOVEMENT’ replacing standard form and activate it.
Now create a document in test client for Material document and go to MIGO, enter MBLNR -> output-> Display Outputs.
Enter a row with Preparation status & details as per configuration.
Select row and click Display document (pdf icon)
2736938 – Settings for processing program and form templates in billing document in new output management
2294198 – SAP S/4HANA output control – customized forms
2608890 – Standard S/4HANA Output Control settings for Purchasing (output forms and processing programs)
ABAP Topic: https://community.sap.com/topics/abap,
post and answer questions https://answers.sap.com/tags/833755570260738661924709785639136.