Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Upload excel file on a button click

Hello,

Please see my earlier thread https://forums.sdn.sap.com/message.jspa?messageID=5873692.

I was able to upload .txt file using this code. But uploading .xls file does not work.

var sFile;
event.target.importDataObject(sFile);

var oFile;
oFile = event.target.getDataObject(sFile);
pa0001.Subform.FILENAME.rawValue = oFile.path;

var cFile;
cFile = event.target.getDataObjectContents(sFile);
pa0001.Subform.filecontent.rawValue = util.stringFromstreams(cFile,"utf-8");

Is there anyway to 'decode' excel file content and bind it to a field in AIF?

Thanks in advance

Sagar

Former Member
Not what you were looking for? View more on this topic or Ask a question