cancel
Showing results for 
Search instead for 
Did you mean: 

Regenerate PDF copies of invoices

Former Member
0 Kudos

Hi Experts,

I have a question in billing related output processing.

Scenario/Requirement: My company (ABC) is acquired by some other company (XYZ). Now company XYZ is requesting us to give thes soft copies of invoices in SAP in a PDF format that they will store in some data ware house.

I imagine that it is some form of a customer program that we need to write to regenerate the old invoices in PDF format and also give us an option to download the file to a local folder.

Has anyone faced such kind of a situation earlier? if you did can you let me know some details like what functional module(s) you used to pull this etc.,

Helpful answers will definitely be rewarded.

Thanks,

Sravani

Accepted Solutions (1)

Accepted Solutions (1)

former_member1115366
Active Participant
0 Kudos

Vishnuu2019s suggestion would work. Here is an alternative that works for sapscript output. It might work for smartforms, but I have never tried it. It involves a new output type, an LSMW to open and save each invoice, and an LSMW for a SAP program to convert spool requests into PDF files.

Configure a new output type for the invoices. Assign the same layout set as your u201Cnormalu201D invoice output type. Assign a key combination that is simple to set up a condition record for all of your invoices (like u201CSales Orgu201D). Add the new output type to your billing output procedure. Transport to your target system.

In the target system,

1. Create the condition record for the new output type. Assign medium 1 (print), date/time 4 (immediate), and assign a u201Cdummyu201D output device that will not really print anything.

2. Create an LSMW to open and save a billing document via t-code VF02. With the new output condition record in place, each execution of VF02 will generate a spool request for the output (that will not print since you assigned a dummy printer). Run the LSMW for all of the invoices that you need to process.

3. Create another LSMW to execute program RSTXPDFT4 for each spool request sitting out there waiting on the dummy printer. You can get a list of the spool requests from table TSP01. Specify the spool request number and network path/file name for the selection screen in your input file.

Regards,

zKen

Former Member
0 Kudos

Hi,

Thank you for the alternative thought as well. If we decide to take the method you suggested I will get back to you with more questions.

Thank you very much for the reply.

Sravani

Answers (1)

Answers (1)

Former Member
0 Kudos

You can create a program that uses function RV_MESSAGE_UPDATE to insert output type that triggers the PDF in the Header -> Output screen of the invoice. The program can be driven invoice number as selection.

To know how to fill the interface of the above function use RV_MESSAGES_READ to read the NAST entry details from existing invoice. Fill the values in RV_MESSAGE_UPDATE similarly as the output of RV_MESSAGES_READ

Once done, you can process all these invoice using RSNAST00 to print the PDF invoices to spool

Former Member
0 Kudos

Hi Vishnu,

Thank you for the reply, at this point we are still in the design mode, we are contemplating our options other than the programming at the moment. I will share this piece of information with my programmer. Once we decide which path we want to take and start developing the program, I will get back to you with more questions if I have any.

Thank you very much for the reply.