cancel
Showing results for 
Search instead for 
Did you mean: 

Delphi and RFC call to SAP

JariYlitolonen
Explorer
0 Kudos

Hi !

Could anyone give short description how Delphi -program can access SAP using RFC. I'm not the one how writes the code and I don't know anything about Delphi. I'm doing the SAP side but I have to give help to person who does the Delphi code. So I need SAP RFC and Delphi for dummies

Best Regards

Jari Ylitolonen

Accepted Solutions (0)

Answers (1)

Answers (1)

CountZero
Explorer
0 Kudos

Hi Jari,

It has been about 8 years since I have used Delphi so this may be slightly out of date. What you need to do is add the following OCXS to the Delphi project

wdtfuncs.ocx (RFC control)

wdtlog.OCX (Logon control)

(these should be on your PC in the SAP GUI directory).

If these are not on your Delphi developer's PC then you need to copy them across along with LIBRFC32.DLL and WDTAOCX.OCX. (I am not sure if the last one is required or not)

These also need to be registered (if the SAP GUI is installed then they will already be registered so miss this bit out).

So run

regsvr32 (full path and file name to librfc32.dll)

regsvr32 (full path and file name to wdtaocx.ocx)

regsvr32 (full path and file name to wdtfuncs.ocx)

regsvr32 (full path and file name to wdtlog.ocx)

You should be able then to call RFCs using wdtfuncs.ocx (do a search for "SAP.Functions") for some examples about how to use. The examples will probably be in Visual Basic though.

We had a number of issues with installing the above files onto machines if LIBRFC32.DLL is registered in more than one location for example causes errors.

So if there are any major issues I would suggest installing the SAP GUI on the developer's PC.

Thanx

Nathan