Now that you have configured your OpenEdge project and set up the Windsurf development environment, you are ready to execute ABL procedures efficiently. This topic introduces multiple ways to run your code, from simple keyboard shortcuts, ABL commands provided by the Riverside extension to automated task configurations, so you can test, debug, and deploy with ease. Whether you are launching teletypewriter (TTY)-based applications using _progres.exe or graphical user interface (GUI)-based applications with prowin.exe, Windsurf provides flexible options to streamline execution. You also learn how to bind custom shortcuts, define reusable task files, and manage startup parameters for real-world scenarios.

Use keyboard shortcuts

You can execute ABL code directly using the following shortcuts:
Shortcut Action
F2 Runs the current procedure using _progres -b. Utilizes the configured PROPATH and database connections.
CTRL+SHIFT+PABL: Run with prowin Executes the procedure using prowin.exe.
To bind prowin.exe execution to the F2 key:
  • Open File → Preferences → Keybinding Shortcuts or select the Configure Keybinding icon.
  • Delete the existing F2 binding and assign it to ABL: Run with prowin.
Note: Running your code with prowin.exe may not be suitable for real-world applications that require specific database connections or startup parameters.

Use the ABL execution commands

The Riverside plugin adds the following ABL execution commands to Windsurf:

ABL: Run with _progres -b—Compiles and executes your ABL code in non-interactive batch mode. No character or graphical UI is displayed. After running the program, switch to the Output panel (ABL Batch) to view the ABL output.

ABL: Run with _progres—Starts an interactive character (ChUI) session. You can view the terminal-based ABL output in the Terminal panel.

ABL: Run with prowin—Runs the current ABL procedure using prowin.exe and launches the output in GUI mode.

These commands are intended for quick testing and validation and require no additional configuration.

Automate ABL code execution with external tasks

Windsurf supports external task definitions stored as JSON files to automate the launching of both TTY-based and GUI-based OpenEdge applications directly from Windsurf. These tasks can be version-controlled and shared across teams.

TTY application startup task:

To run a TTY-based OpenEdge application using _progres.exe:

  1. Create a file named .vscode/tasks.json in your project directory. This file defines how Windsurf should launch your OpenEdge application using specific parameters like:
    • Database connection: -db, -H, -S
    • Procedure file to run: -p test2.p
    • Environment variables: DLC, PROPATH
    • Executable path: _progres.exe for TTY, prowin.exe for GUI
  2. Define the TTY task configuration in tasks.json. Here is an example configuration:
    {
      "version": "2.0.0",
      "tasks": [
        {
          "label": "My TTY Application",
          "type": "process",
          "command": "/path/to/nowhere",
          "args": [
            "-basekey", "INI",
            "-ininame", "conf/empty.ini",
            "-db", "sports2020",
            "-H", "localhost",
            "-S", "12345",
            "-cpinternal", "1252",
            "-p", "test2.p"
          ],
          "windows": {
            "command": "C:\\Progress\\OpenEdge\\bin\\_progres.exe"
          },
          "presentation": {
            "reveal": "silent",
            "panel": "new",
            "focus": true
          },
          "options": {
            "env": {
              "DLC": "C:\\Progress\\OpenEdge",
              "PROPATH": "rcode,C:\\Progress\\OpenEdge\\tty\\netlib\\openedge.net.pl,
                C:\\Progress\\OpenEdge\\tty\\openedge.core.pl"
            }
          },
          "problemMatcher": []
        }
      ]
    }
    Note: This example assumes your workspace includes an aconf directory containing an empty INI file named empty.ini.
  3. Open a Proenv terminal in Windsurf and navigate to your database directory:
    cd C:\Workspace\myProject\db
  4. Start the database broker:
    startDb.bat
    The database broker starts on port 12345.
  5. To update project configuration, remove the -RO (read-only) option from the database connection in openedge-project.json. Removing -RO allows the application to write to the database, which is required for tasks that modify data. After you have removed this option, restart the ABL language server to apply changes.
  6. From the Terminal menu, select Run Task and choose the configured task.

    A new terminal opens with your _progres application running.

    Note: If you remove the QUIT statement from test2.p, executing the task launches the Procedure Editor, similar to running from the command line.

GUI application startup task

To run a graphical OpenEdge application using prowin.exe:
  1. Create a file named .vscode/tasks.json in your project directory.
  2. Define the GUI task configuration in tasks.json. Here is an example task configuration:
    {
      "label": "My GUI Application",
      "type": "process",
      "command": "/path/to/nowhere",
      "args": [
        "-basekey", "INI",
        "-ininame", "conf/gui.ini",
        "-db", "sports2020",
        "-H", "localhost",
        "-S", "12345",
        "-cpinternal", "utf-8",
        "-p", "test2.p",
        "-nosplash"
      ],
      "windows": {
        "command": "C:\\Progress\\OpenEdge\\bin\\prowin.exe"
      },
      "presentation": {
        "reveal": "silent",
        "panel": "new",
        "focus": true
      },
      "options": {
        "env": {
          "DLC": "C:\\Progress\\OpenEdge"
        }
      },
      "problemMatcher": []
    }
    Note: This example assumes your workspace includes an aconf directory containing an INI file named gui.ini.
    Here is an example of the gui.ini file:
    [Startup]
    V6Display=no
    DefaultFont=MS Sans Serif, size=8
    DefaultFixedFont=Courier New, size=8
    DLC=C:\Progress\OpenEdge
    Use-3D-Size=Yes
    PROPATH=rcode,C:\Progress\OpenEdge\tty\netlib\openedge.net.pl,C:\Progress\OpenEdge\tty\openedge.core.pl
    UseSourceEditor=yes
  3. Update the conf/gui.ini file to reflect the correct paths for DLC and PROPATH.

  4. From the Terminal menu, select Run Task and choose the configured task.

    A new terminal opens with your prowin application running.

Note:
  • CTRL+1 returns focus to the Editor view from the Output view.
  • Store task configurations in your code repository to share across teams.
  • Refer to the full Windsurf documentation for advanced task setup and environment configuration.