cancel
Showing results for 
Search instead for 
Did you mean: 

Download & save pdf file (mail to file scenario)

Former Member
0 Kudos

Hi All,

I have a simple scenario (mail to file), in which pdf file is being attached to incoming mail message. Attachment is "downloaded" (using localejbs/AF_Modules/PayloadSwapBean adaptor module(.

Since no mapping required, the used "Integrated Configuration".

my scenario works fine, no ERR and pdf file is created at target directory.

When I'm trying to open the file the adobe is showing to following err msg:

"Adobe Reader could not open 'xi_output.pdf' because it is either not a supported file type or because the has been damaged.."

What can be done, to bypass the problem? Please advice.

Regards,

Uri

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

please note:

I've re-tested the scenario with xml file (as mail attachment) and it works OK.it seems only option is that the attached pdf can not be swapped (via localejbs/AF_Modules/PayloadSwapBean).

is it correct assumption?

Regards,

Uri

former_member187339
Active Contributor
0 Kudos

Hi Uri,

I have few doubts, please re-check

1. Are you able to open the pdf in the mail?

2. What is the content-type of pdf attachment in SXMB_MONi, Try to change it to application/pdf before you write it as a pdf. You can try to use MessageTransformBena before payloadswapbean in receiver channel

Regards

Suraj

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

>>>What can be done, to bypass the problem? Please advice.

if you're sending the correct pdf probably the swappayload bean didn't work in your case

try to open xi_output.pdf with notepad and if you see the main message (and not some binary data) then

the bean didn't work

Regards,

Michal Krawczyk

Former Member
0 Kudos

Hi,

Thanks for your replay. Your observation was absolutely correct!

I used /people/michal.krawczyk2/blog/2005/12/18/xi-sender-mail-adapter--payloadswapbean--step-by-step (yours) as a reference; it worked OK (while I used it in other scenario). The only difference is that my current scenario is based on "Integrated Configuration", does it make sense?

What can be done?

Regards,

Uri

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

>>>The only difference is that my current scenario is based on "Integrated Configuration", does it make sense?

hmm this should work in the very same way with ICO but I never tested it with it frankly speaking

but the adapter module works on the same adapter as without ICO so why should there be a difference

(the swaping is done before the message is delivered to the IE or AAE processing)

but you can try writing a note to SAP to crosscheck if this module works with local AAE

Regards,

Michal Krawczyk

former_member187339
Active Contributor
0 Kudos

Hi Uri,

I guess the parameters in the receiver channel are having some problem. Can you cross check with the correctly working scenario ( the one which is not configured as Integrated Configuration)

Regards

Suraj