on 01-26-2010 2:46 PM
Hi forum,
I have a problem. I converted a smartforms to PDF and sended to function SO_DOCUMENT_SEND_API1 to send a mail external...
So, when I tried to open the file attachment, I can't open this file. and I watch a message : 'The file is damaged'. But in ocations the file can opened.
SAP system is connected to CITRIX. can this be a problem?
Regards,
Jhon R.
Hi,
First of all do which function do you use to convert your smartforms result to PDF ?
Then i agree with Sandra, please don't use anymore function SO_DOCUMENT_API but use classe CL_BCS . With it a lot of bug disapears and it works very fine . If you need i can give you more detail on how to use it.
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ABAP Gurus ,
Good Morning !
I converted a smartform to PDF and sended to function SO_NEW_DOCUMENT_ATT_SEND_API1 to send a mail external...
So, when I tried to open the file attachment, I can't open this file. and I watch a message : 'There was a error in opening the document . The file is damaged and could not be repaired '.
In one of the earlier threds on www. sdn.sap.com i found a solustion which says to use class CL_BCS but I don't know how to use this class or rather use classes in ABAP Programs .
I would be thankful if I am provided the sample code or some help regarding this issue .
I think if somebody provides a solution on how to use function SO_NEW_DOCUMENT_ATT_SEND_API1 that would make me Relieved .
Regards,
D Singh
Myles and Rani, thank you for your valuable feedbacks.
I just wanted to see what was behind this note, as for me the SO_NEW_DOCUMENT_ATT_SEND_API1 function module has always correctly worked (though very tough to make it work! This FM should be definitely abandoned, and we should use always BCS).
This note says:
> Either the calling program does not specify a document size (which should not be absolutely necessary), or the binary documents are transferred to a text table (type SOLI) in a Unicode system (which is not recommended).
So, if you pass the length with the right value or pass binary document as binary (CONTENTS_HEX parameter if I remember well), then there should be no problem.
PDF damaged, same question again and again... (if people could stop using this old SO_... function module, and use CL_BCS instead, that would limit the bugs and questions!)
Citrix, I don't see where it could impact the mail as the mail is prepared only within SAP and sent externally.
Either extra blanks or zeroes in the PDF. When you convert into PDF, SAP sends back a binary length, you have to transmit it unchanged when adding the attachment to the mail, same thing for binary value of the PDF. To make sure, check length and PDF binary value by debug, and compare it to the attachment you download from the mail to your computer.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.