on 07-31-2007 6:58 PM
I have the requirement to read a particular worksheet from a particular XLS spreadsheet into a webdynpro application. This data is used to update SAP 'Z' tables.
I have created a routine to open and read a sheet using OLE but this does not seem to work when called from webdynpro. I have also used the Upload File element but it creates a XSTRING and from what I can see there is no way to read this XSTRING into its contents for XLS.
I can also read a comma delimited file but the business does not want to have to export the XLS to comma delimted everytime.
Anyone have any suggestions> At this point I am looking at using standard SAP GUI as it seems to have the functionality required just not as pretty...
Glenn
Hi Glenn,
you are right about OLE.
It uses the GUI to talk to Excel.
Most standard functions that pick up the XLS data also use OLE to get at individual cells.
2 ideas:
a) USE sapgui and embed an HTML control shows your web dynpro.
See function wdy_execute_in_place.
OLE functions are still available now.
b) It maybe possible (I say maybe as I havent tried it) , to use the IOS factory class
available when in expert mode on UI element.
See interface IF_IOS_FACTORY.
From here get spreadsheet proxy IF_IOS_SPREASDHEET
I cant see any methods to provide cell level access to data ???
AS is possible for the OLE .
Otherwise as you see, the data is available in WDA but as XSTRING.
If you need to analyse the content and cant export as XML or csv,
then I would also stay with SAPGUI for cell level access via OLE.
regards
Phil
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
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.