When calling a function module in the SAP system it may be necessary to start a SAP GUI on your client.
Some (older) BAPIs need this, because they try to send screen output to the client while executing.
● If you want to start a SAP GUI on an external client, your SAP backend system must meet some requirements. You will find detailed information in SAP note 1258724.
● You have installed the Windows SAP GUI or Java SAP GUI (Unix) on your system.
To start a SAP GUI from your client program, proceed as follows:
Set the property USE_SAPGUI to 1 (hidden) oder 2 (visible).
Possible values are:
● 0: no SAP GUI (default)
● 1: attach a "hidden" SAP GUI, which just receives and ignores the screen output
● 2: attach a visible SAP GUI.
Set the envrionment variable via:
setenv SAPGUI <pfad zum SAPGUI startskript> (tcsh) or
set SAPGUI=<pfad zum SAPGUI startskript> (bash)
For Mac OS the path name could look like this:
"/Applications/SAP Clients/SAPGUI 7.10rev7.3/SAPGUI 7.10rev7.3.app/Contents/MacOS/SAPGUI"
For Linux and other Unix systems the following path would be valid:
You must not add any parameter after the script name of the environment variable.
Start the external application from the same shell to propagate the environment variable to the program.