03-05-2018 1:20 PM
Hi All,
I am calling a transaction MIRO or FB60 through custom program to create the invoice document, once the invoice document gets created then I attached a file to the document which is stored in DMS server. In DMS I am able to open the file correctly but when I open the same file in invoice document (MIRO, FB60) , it opens in corrupted format. While other formats like .doc, .pdf, .jpg are getting open correctly. Your valuable inputs are very much appriicated.
03-05-2018 6:22 PM
If it's "corrupted" then Excel wouldn't be able to open it at all. Please provide more details, as well as a screenshot of what exactly is happening.
Also try if this works with XLS format.
03-06-2018 7:15 AM
please move it to your original question. "Answers" are reserved to solutions.
03-06-2018 8:04 AM
Hi Jelena thanks for you response. As I already said that file is already stored in DMS server, which I am able to open in cv03n in corrected or readable format but it is coming in corrupted format as shown in below screenshot. I tried to save the file in .XLS format but it is not working, shows the same corrupted format.
DMS server ( if file is in .XLS ) - GOS attachment ( It's working fine )
DMS server ( If file is in .xlsx ) - GOS attachment ( It is giving unreadable format, when I try to save it in .xls format still gives the same error )
If required I can share my code also.
03-06-2018 8:12 AM
Hi
It looks like the mime type for XLSX is incorrect or missing
please check Tx OAD2 or DC30
regards
Domi
03-06-2018 8:12 AM
It's showing the XLSX file as if it was simple text (we can see "PK" at the beginning which usually indicates it's a ZIP file, an XLSX being a ZIP file with a specific hierarchy of files)
Please download the file on your desktop and open it. Does it open correctly?
Did you indicate &SO_FILENAME=filename.xlsx in the header while attaching it? (cf note 1582868 - GOS: Support for four-character file name extensions)
03-06-2018 9:54 AM
Hi Sandra,
I have downloaded it on desktop and checked but it is giving the same issue.
I have used the FM SO_OBJECT_INSERT to attach the file, where I am passing a parameter as a file name ( filename.xlsx ).
03-06-2018 5:29 PM
According to me (according to the note 1582868), you must pass the parameters OBJECT_TYPE = 'EXT' and OBJHEAD = VALUE soli_tab( ( LINE = '&SO_FILENAME=filename.xlsx' ) ) (use a valid ABAP syntax of course)