GS/TR/FM SAP GUI vs Transaction vs Function Script

EasyInput Frequently Asked Questions
moderator
Posty: 138
Rejestracja: śr cze 22, 2016 7:45 pm

GS/TR/FM SAP GUI vs Transaction vs Function Script

Post autor: moderator » pn kwie 23, 2018 1:53 pm

EasyInput workbook configuration is based mostly on scripts. Scripts connect entered/ received data with SAP system elements.
There can be one (usually the case) or more scripts within one EasyInput workbook.

There are three script types used:
  1. SAP GUI Script - Scripts based on SAP GUI Scripting created by SAP. This kind of scripts takes control of SAP GUI and imitates SAP GUI manual use. This is a very powerful script type, but sensible to any GUI screen changes (e.g. after upgrades or configuration changes). SAP GUI scripting is best suited for business users’ self-service. These scripts can be easily recorded, can handle any transaction, which can be used with SAP GUI. Unfortunately, these scripts are easily affected by slight customizing changes or system upgrades.
  1. Transaction Script (batch Input) - script based on recorded SAP transaction. This kind of script is sometimes called batch input script, as the technique used to call transaction remotely is called batch input. To prepare such a script, recording transaction with transaction recorder (SHDB transaction) is needed. Check the exmaple workbooks starting with "EasyInput_TR_" to see how transaction script can be used.
  1. Function Script (BAPI) - script based on remotely executed SAP functions. The functions have to be exposed as remotely accessible function modules. SAP provides a huge list of predefined remotely accessible function modules in its BAPI interface. To prepare such a script one has to choose the right function module ID. For the standard, predefined interface one can use BAPI Explorer (BAPI transaction) to look for the right function module ID. Check the exmaple workbooks starting with "EasyInput_FM_" to see how functional script can be used.
Which script technique should I use?
Usually recording a known transaction can be easier for business users than analyzing function module interface. Thus for business users as a start point, SAP GUI script or transaction script seem to be a better choice. On the other hand, function scripts usually do not need adjustments with upgrade/ SAP system changes. Thus if there is a choice, users are encouraged to prepare EasyInput workbooks based on BAPI function modules.

When there is a choice between SAP GUI script and transaction script, then depending on some critera on can choose:
- if the script is to be used only by the creator, then SAP GUI scripting is often easier to record, and can be adjusted by the creator in future if needed,
- if the script only writes data to SAP and does not have to fill multiline description fields then the transaction script is usually better,
- if the script is to read data from SAP, or fill in multiline description fields or cannot be recorded as transaction script then one should use SAP GUI Script,

ODPOWIEDZ