The external call of an InputScript is performed by starting guixt.exe
with the parameter input=. In 64‑bit SAP GUI the call is:
C:\Program Files\SAP\FrontEnd\SAPGUI\guixt.exe input=OK:process=myinputscript.txt
and in the 32‑bit version:
C:\Program Files (x86)\SAP\FrontEnd\SAPGUI\guixt.exe input=OK:process=myinputscript.txt
This allows you, for example, to upload data into SAP or read data from SAP from Excel or Word via a custom button and a VBA macro. Batch‑type processes can also be automated in this way.
In addition to the name of the InputScript, you can also specify parameters and an SAP GUI OK code. Example:
guixt.exe input="U[ORDER]:27853;OK:/VA03,process=display_customer_order.txt"
AllowExternalInput YesThis security measure was introduced with GuiXT version 2026 Q1 1.
When the input= parameter is used, GuiXT looks for an SAP GUI session
in which no InputScript is currently running and starts the specified script there.
If all sessions are already executing an InputScript, GuiXT waits until a session
becomes free. All calls of guixt.exe input=... are buffered internally
during this time.
When multiple sessions exist, InputScripts can be executed in parallel.
In certain situations, selecting a specific session is required, e.g.:
The selection is done using the additional option findsession=:
guixt.exe findsession="system:'S4H'" input="OK:process=se37.txt"
GuiXT creates an identifier for each active session containing the following attributes:
system:'PS4' user:'MSMITH' client:'100' transaction:'VA01' mode:'1' hwnd:'133842' processid:'11000' mysessionname:'CUSTOMERORDER'
The order of these attributes will remain stable in the future.
The regular expression specified in findsession= is evaluated case‑insensitively.
(a) Only sessions of system PS4:
guixt.exe findsession="system:'PS4'" input=...
(b) Only sessions for user msmith:
guixt.exe findsession="user:'msmith'" input=...
(c) Selection by window handle:
guixt.exe findsession="hwnd:'133842'" input=...
The window handle corresponds to the GuiXT variable V[_hwndguiscreen]..
(d) Combination of conditions:
guixt.exe findsession="system:'PS4'(?s).*?user:'MSMITH'" input=...
(e) Use the session name:
guixt.exe findsession="mysessionname:'BATCH01'" input=...
In GuiXT you set the session name as follows:
Set V[_mysessionname] "BATCH01"
If no matching session is found, the call is ignored. If sessions exist but all of them are currently executing a script, GuiXT creates a queue for each search expression.
Parameters are passed using:
guixt.exe input="U[par1]:value1;U[par2]:value2;OK:process=myinputscript.txt"
In the InputScript:
Parameter par1 Parameter par2
The number of parameters is unlimited.
The values passed should contain neither ; nor ".
If this is required, use one of the following approaches:
When using temporary files, filenames must be unique since the calls are processed asynchronosly.
GuiXT does not create its own log entries for externally started InputScripts; however, the InputScript trace is available.
For more complex applications, a custom log documenting the start, end, and possibly the parameters of each call is recommended.
To open a new SAP GUI session with a specific name, process some InputScripts, and then close the session, you can use the following procedure:
guixt.exe input="U[sessionname]:BATCH01;ok:/O0,process=set_session_name.txt"
guixt.exe findsession="mysessionname:'BATCH01'" input="..."
guixt.exe findsession="mysessionname:'BATCH01'" input="..."
...
guixt.exe input="U[sessionname]:BATCH01;ok:/i"
// InputScript "set_session_name.txt"
Parameter sessionname
// set session name
Set V[_mysessionname] "&U[sessionname]"
Return
rdisp/max_alt_modesthe value can be increased to up to 16, which is already set as the default value in newer SAP systems.