Highlighted
Absent Member.
Absent Member.
1725 views

Creation of an 'Icon' for my built VC executable?

Jump to solution

Having build several Visual COBOL executables I want to deploy them onto peoples desktops.

Rather than have a bog standard 'window' icon on my desktop I'd like to have them as small icons we've got artwork & images for.

How do I build the executable so that these 'images' can be seen as the desktop icon rather than the 'window' icon?

 

0 Likes
1 Solution

Accepted Solutions
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Creation of an 'Icon' for my built VC executable?

Jump to solution

Look at the Microsoft article here:

Basically just open up project properties to Application tab and select the icon that you want to use for the application:

View solution in original post

0 Likes
4 Replies
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Creation of an 'Icon' for my built VC executable?

Jump to solution

Look at the Microsoft article here:

Basically just open up project properties to Application tab and select the icon that you want to use for the application:

View solution in original post

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: Creation of an 'Icon' for my built VC executable?

Jump to solution

Hi Mark,

The icon that Windows displays for a program file is actually the first icon resource in its EXE file. If the EXE file has no icon resources, a standard icon is displayed. To link such icon resources into the EXE you have to have a resource file that contains your icon, you can link it into the produced executables.

In the case your resource file is a precompiled resource file (*.res) you can link it into the executable by specifying it as a additional link file. To do so right click on your project and choose Properties and in the opened dialog choose Micro Focus -> Build Configurations -> Link -> Additional Link Files. If the *.res file is inside your project you can add to the list by choosing "Add Files..." button. Otherwise you can use "Add External Files..." button to browse your local file system for the resource file.

In the case your resource file is a resource script (*.rc), you can add it to the project together with the icon file. Then you can invoke Microsoft resource compiler (rc.exe - part of Windows SDK) in the pre-build event script. You can add a pre-build event by right clicking on your project , then Properties and then Micro Focus -> Build Configurations -> Events. The pre-build script you have to add is something similar - rc.exe resourcefilename.rc. Then you can add the compiled resource file as Additional Link File so to have your icon built into the executable.

I hope the suggestions above will help you having a custom icon built into the EXE.

Thanks,

Sezgin

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: Creation of an 'Icon' for my built VC executable?

Jump to solution

Just to add that my suggestions are for Visual COBOL for Eclipse.

Regards,

Sezgin

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: Creation of an 'Icon' for my built VC executable?

Jump to solution

Excellent.

I found a tool called IRFANVIEW which took our images and converted them to .ICO files.

I then refered to these files in the Icon & Manifest option.

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.