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.

UseNewConsole property

Project: Console Application Runner Classes

Unit: PJConsoleApp

Classes: TPJCustomConsoleApp, TPJConsoleApp

Applies to: ~>3.0

property UseNewConsole: Boolean;

Description

UseNewConsole determines whether a console application is run in a new console window or whether it shares any console of the parent application.

Set UseNewConsole to True if you want the child console application process to be started in a new console window. Set the property to False to force the child process to use the same console as the parent.

If the parent process does not have a console window (for example in a GUI program) then the child process always gets a new console window regardless of the value of UseNewConsole.

The property defaults to False.

Remarks

Whether any new console window is actually displayed depends on the value of the Visible property.

The characteristics of a new console window can be customised using the following properties:

These properties are ignored if the console application shares the parent’s console.

The property is public in TPJConsoleApp and protected in TPJCustomConsoleApp.