Connect to SAP using sapjco in Java.

Environment

  • OS: Windows10
  • Java version: 1.8
  • Library: sapjco3

Import libs

Reference files: saro-lab/sap-jco-manager on Github

Sapjco.jar can also be find in this site: JAR download

  1. Sapjco3.dll is needed to put in "C:/windows/system32/" or "C:/windows/SysWOW64/". (Depends on your running environment.)

  2. Import the sapjco3.jar into your project.

Codes

Devided into 3 parts:

  1. SAP connection configuration class.
  2. Functions to connect to SAP.
  3. RFC.

SAP connection configuration class

Functions to connect to SAP

RFC

Send data to SAP Using RFC

Above, ArrayList and are defined by user. You can use other struct design.

最後修改日期: 2021-04-01

留言

撰寫回覆或留言

發佈留言必須填寫的電子郵件地址不會公開。