I am trying to use ole to read excel spreadsheet into my abap program. I have downloaded a sample program which keeps crashing on me. I do not know how to resolve the issue because I do not understand the ole concept.

Can you give me a brief explanation of how this works and a sample working code if possible?

    Requires Free Membership to View

OLE is notoriously difficult to use. You need to determine the VBA commands on the Excel side, to achieve what you want to do. Once you have determined these, you can then write the ABAP to do it, using the CREATE OBJECT, CALL METHOD and SET/GET PROPERTY OF etc. keywords. The sample code provided by SAP, RSOLETT1, is very good - and it does work, provided you have your enviroment correctly set up - you might need to speak to your basis team about this.

One of the easiest ways to use OLE, is to write a VBA macro in Excel for your task, and call that from SAP.

A simpler solution might be to save your spreadsheet as a tab delimited flat file. Then you can use WS_UPLOAD function module, or READ DATASET to read the values into your program.

This was first published in July 2001

There are Comments. Add yours.

TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: