cancel
Showing results for 
Search instead for 
Did you mean: 

OTF from application form (print workbench EFRM, EFG_PRINT_EXPANDED)

Former Member
0 Kudos

Hi,

<b>Does anyone know how to retreive an OTF file while printing an application form?</b>

Before you start replying: This is a much more complex question then you might think. This is about an application form, printed from within standard SAP batchprograms (part of FICAx), and the call function l_genfunc is done deeply within!

So if your still here and interested, please help me out.

From several FICAx transactions interest and dunning invoices are printed. We need to get the OTF back and do not want it to go to the spool.

- There are a lot of events available (through FQEVENTS), also for form printing (i.e 0702), but these do not have the <b>results</b> table available.

- I tried to use the userexit event available within the application form. User_exit_start_exit... and user_exit_end_exit... . The first one is used to change some print parameters (i.e. TDGETOTF = X), the second one to get the results table. But the results table stays empty, because the CLOSE_FORM is called but within function SSF_CLOSE is not performed because parameter x_NO_CLOSE_FORM has value 'X'. Because the close form is not executed (at this time) the result table is empty when my exit is reached. I tried to clear the parameter x_NO_CLOSE_FORM in the start_exit, but that can result in a X-dump (hierarchie error EZ405) when processing multiple prints.

So, does anyone have a better Idea on how to change/set the x_NO_CLOSE_FORM in an earlier stage or any other better way to get this to work.

Thanks,

Hans

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Problem was solved by using the standard available application forms userexits '...before... and ...after... printing'. We set the parameter in the before, so that the result (OTF) can be processed in the after exit.

Former Member
0 Kudos

Hi Hans,

Could you please explain where are the userexits '...before... and ...after... printing' in the the standard available application forms .

Because I have found only the PERFORM PROCESS_AFTER_FORM ( execute processes after the printing).

.

Thanks for you answer.

Mary

Former Member
0 Kudos

Hi Mary,

It is a long time ago since I worked on that subject, and I'm also no longer working for that customer. So here is my best shot...

Within transaction EFRM you create an application form. If you select radiobutton attributes and press change, you get a popup where you can enter User exit include, User top include, Start Exit and End Exit. Enter some logical names like ZI_XX_USEREXITS, ZI_XX_USER_TOP

START_EXIT and END_EXIT resp. Press the white create buttons to create the includes and forms.

You now have two includes and in the first one there are two forms USER_EXIT_START_EXIT and FORM USER_EXIT_END_EXIT.

Enter your code there.

Combine your logic in START_EXIT and END_EXIT to get the OTF.

If I remember correct, we extracted the OTF in END_EXIT and then changed it to pdf and sent it to ...

Unfortunately I do not have any code snippet for you.

Regards Hans