
Defining and Generating a Binding: BAPI
Prerequisites
You have created a form in Microsoft Visual Basic and have called the
SAPforms Designer as an add-in and loaded the BAPI structure. The form controls are shown in the table displayed in the bottom screen area. You have selected the BAPI that you want to call. The interface description of the BAPI is displayed in the top screen area of the SAPforms Designer.
Procedure
You must now assign the individual segment parameter of the BAPI to the fields in the current SAPforms form (binding definition). This assignment is stored as part of the SAPform form and is used at runtime to transfer data from the form to the SAP System.
You can release the binding by selecting the required row in the table and choosing Binding
The General tab on the SAPforms Options dialog box is then displayed.

This step is only necessary the first time you generate your SAPforms form and if the SAPforms form does not already have these pushbuttons. Otherwise, it is possible you will receive an error when compiling the SAPforms form because the declarations and event procedures are contained twice in the source text. You must remove the duplicate source code from the SAPform form by hand.
Result
The SAPforms form is now complete. You can now start it in Microsoft Visual Basic by choosing Run or create an
EXE file.
The procedure is the same if you are using the stand-alone version of the SAPforms Designer.