Change icon for a Delphi console application

console-application, delphi

Solution

According to a July 2007 blog article by Nibu Thomas, there seems to be a `SetConsoleIcon` WinAPI function.

Alternatively just put the icon in a resource file. Windows should use the first icon it encounters in the application's resources as the application icon.

Problem

How do I change the program icon for a Delphi console application? The application settings is greyed in a console application. Bye.

Original source