Purpose With Returnvalues you can return values from a new mode, opened with “/O…,process=… “, to the old mode. As target fields, both entry fields and variables can be used. It is also possible to invoke a function code and to start an InputScript.

Returnvalues “Material:&V[mat];Amount:&V[amnt]“

The content of the variable  V[mat] (new mode) is set into the entry field  Material (old mode), and the content of the variable  V[amnt] (new mode) is set into the entry field Amount (old mode).

Returnvalues “V[mat]:&V[matnr]“

The content of V[matnr] (new mode) is set into variable V[mat] (old mode).

Returnvalues “U[MATNR]:&V[matnr];OK:/8,process=next.txt”

In the old mode, function key F8 is invoked and the InputScript “next.txt” is started.  Parameter U[MATNR]of the InputScript gets the value of variable V[matnr] (old mode).

Format Returnvalues string

The string syntax is the same as documented in  Image for  the parameter Input="...".

& Tricks
  • It is also possible to return several variables with a series of Returnvalues commands, or to return the content of a textbox. Example:
    In one transaction, use the following GuiXT script, where xxxx is a new transaction code (e.g. SE37 for testing):

    Pushbutton (toolbar) “Test Returnvalues” “/Oxxxx” process=“tv.txt”

    Offset (10,0)
    Text (0,0) “&V[t1]“
    Text (1,0) “&V[t2]“

    Textbox (2,1) (8,100) name=“txt1″

    The InputScript “tv.txt” can be empty. Then, in the called transaction, use the GuiXT script

    Offset (15,1)
    Box (0,0) (10,42) “Test Returnvalues”
    InputField (1,0) “Line1″ (1,8) size=30 name=t1
    InputField (2,0) “Line2″ (2,8) size=30 name=t2
    Textbox (3,0) (9,40) name=“txt1″

    Pushbutton (toolbar) “return values” process=“rv.txt”

    and the InputScript “rv.txt”

    Returnvalues “V[t1]: &V[t1];”
    Returnvalues “V[t2]: &V[t2];”


    Returnvalues “OK:/0″

    Enter “/i”