• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 437
  • Last Modified:

Change Icon in console app

How do i Change the Icon in console application? i dont want the standard .exe icon.
and also can you change the icon programatically based on parameters?
1 Solution
Wim ten BrinkSelf-employed developerCommented:
Create an *.rc file with the following contents:

MAINICON ICON "YourIcon.ico"

And make sure you have an icon file named YourIcon.ico in the same folder. Next add:

{$R 'Yourfile.res' 'YourFile.rc'}

to the main source of your project. This will compile the YourFile.rc to an *.res file and include it in your console application. Since consoles normally don't have a *.res file with icons, this icon will be the one that's displayed.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now