cancel
Showing results for 
Search instead for 
Did you mean: 

PDF Attachements as mail in Background

Former Member
0 Kudos

Hi,

I am calling two different ABAP programs using their variants in another ABAP program.I am getting the spool numbers for each programs also. But , When I am trying to send those spool as PDF attachments, the two attachments are showing the same data only.

Is there any other work around is available to solve this?.

Regards

Elini.P

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

If you are using this function module, make sure you refreshed the table 'compressed_list'.

call function 'RSPO_RETURN_SPOOLJOB'

exporting

rqident = spool_number

importing

real_type = g_doc_type

tables

buffer = compressed_list

exceptions

no_such_job = 1

job_contains_no_data = 2

selection_empty = 3

no_permission = 4

can_not_access = 5

read_error = 6

type_no_match = 7

others = 8.

Thanks,

Bala

Former Member
0 Kudos

Hi Bala,

I have checked in debug mode.

Its fetching two different spool requests only.

But when I am converting to PDF and sending those as attachments, for both the attachments contain the same content.

Regards

Elini.P

Former Member
0 Kudos

Elini,

Can you check this first?

Your code should have the following order.

1. new-page print on list name 'Test'.

2. perform write_list.

3. new-page print off.

4. spool_number = sy-spono.

Thanks,

Bala