0% found this document useful (0 votes)
302 views

Bapi

This document provides a 13 step process for accessing BAPIs using Visual Basic 6.0. It includes steps for setting up the form properties, declaring variables, logging on to SAP, setting SAP objects, transferring data to SAP by filling header, detail, and currency amount tables to pass to the BAPI, resetting SAP objects, committing transactions or rolling back in case of errors, and includes some additional subroutines. The goal is to post and check accounting documents by accessing SAP BAPIs from Visual Basic.

Uploaded by

api-3856831
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
302 views

Bapi

This document provides a 13 step process for accessing BAPIs using Visual Basic 6.0. It includes steps for setting up the form properties, declaring variables, logging on to SAP, setting SAP objects, transferring data to SAP by filling header, detail, and currency amount tables to pass to the BAPI, resetting SAP objects, committing transactions or rolling back in case of errors, and includes some additional subroutines. The goal is to post and check accounting documents by accessing SAP BAPIs from Visual Basic.

Uploaded by

api-3856831
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 14

Accessing BAPI

Using
Visual Basic 6.0

By
Vipul & Mangesh
Step 2
• Select Properties Window or press F4.

• Type property Value as shown below.

• Name: FrmBAPIUpload
• Caption: BAPI Upload Accounting
Document
• Height 9180
• Width 14805
Step 3
• From the tool bar given drag & drop controls on the form & place them such that it
appears as below
Step 3
• Go into code window of the form by pressing F7 & declare the following variables in the
General Declaration area.
Step 4
• Place the following code in Command1->Click Section of code window.
Step 5
• Subroutine for logging on to SAP.
Step 6
• Subroutine for setting SAP Objects
Step 7
• Subroutine for Transferring Data to SAP
Step 8
• Subroutine for Filling Header Data into Document Header Structure which is to be
passed to the BAPI to post & check the data.
Step 9
• Subroutine for Filling Detail Data into AccountGL Internal table which is to be passed to
the BAPI to post & check the data.
Step 10
• Subroutine for Filling currency Amount Internal table which is to be passed to the BAPI
to post & check the data.

Step 11
• Subroutine for resetting SAP Objects.
Step 12
• Subroutine for commiting transaction in case of Success or rollbacking in case of error.It
also include code for filling error messages into text file from the return parameter.In
return parameter Message type is ‘E’ for Error & ‘S’ for success.
Step 13
• Some other subroutines used for filling data in Flex Grid & for common functionality.

You might also like