Use a script to set the environment

You can specify environment variables using ENVIRONMENT_VARIABLE elements. Alternatively, you can configure your application to call a script, where the script sets the execution environment and launches the application.

<APPLICATION Id="kiosk" Parent="defaultgwc"> 
  <EXECUTION> 
    <PATH>/home/f4gl/gep/configfiles/officestoredemo</PATH> 
    <DVM>/bin/sh</DVM> 
    <MODULE>gdc-kiosk.sh</MODULE> 
  </EXECUTION>
</APPLICATION> 

<APPLICATION Id="myprog" Parent="defaultgdc">
  <EXECUTION>
    <PATH>$(res.fgldir)/demo</PATH>
    <DVM>c:\myprog\launch.bat</DVM>
  </EXECUTION>
</APPLICATION>
  1. PATH is where the script is stored.
  2. DVM is the command to execute the script.
  3. MODULE is the script file. In our first example, the script file gdc-kiosk.sh sets the execution environment and launches the application (with an fglrun kiosk, for example).