Welcome to the new DelphiDabbler Code Library Documentation.

This is a new site that's currently running on alpha code. There are going to be bugs. If you discover any, please report them on the site's issues page (GitHub account required). Thanks.

Warning: Many URLs are going to change. Refer to the README file to discover which library project's documentation has been completed.

Console Application Runner Classes Overview

Applies to: ~>3.0

This page provides an overview of the features of the Console Application Runner Classes. If you are looking for information on programming with the classes please see the Programmers’ Guide.

The Console Application Runner classes are intended to simplify working with child console application processes.

Here’s a short list of tasks that the classes simplify:

TPJConsoleApp is the main class responsible for console applications. It enables standard input, standard output and standard error to be redirected to and from files or pipes. It can also time-slice the running of the console application to allow the calling application to continue processing and to enable redirected piped output to be processed.

Various other properties of the console application can also be configured, including:

Information about the running process can be read and a console application’s exit code is made available.

If a console application fails to execute information about the error is provided.

TPJConsoleApp descends from TPJCustomConsoleApp, which provides all the functionality of the derived class, except that all properties are protected. TPJCustomConsoleApp should be used if you need to create subclasses. Subclasses should make the required properties public.

Compatibility

The unit can be compiled with any Delphi compiler from Delphi 7 through to 11.3. It is compatible with 32 bit and 64 bit Windows targets.

The code is compatible with both the VCL and FMX frameworks.

Non-Windows platforms are not supported due to the code’s reliance on the Windows API.