We have excel sheets created in webMethods and stored in linux file structure. In linux the file opens as binary content but in windows OS the same opens perfect as excel workbook.
My requirement is to now mail this file.
However when I am trying to pass the workbook object (xssf object) as input to attachment/content in pub.client.smtp , My email receives a corrupted file , ie, it opens with binary content.
Also, I tried converting xssf Workbook object to byte but its not working for me.
Can u pls suggest what should be the content type? For ex: I am opening the org.apache.poi.xssf.usermodel.XSSFWorkbook and get the workbook object opened. What should be the best way to pass the content ?
If I try to convert the workbook object to string it just gives : Name: /xl/workbook.xml - Content Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml
I tried passing the workbook object directly and also after converting to string.