hi all, this is my firist question
am new to programming and wanna know how can I add icon to the executable file I made. I can do the stuff using the Dev-C++ IDE, but now am using CodeBlocks ( I think its better - or suggest me one). If there is another software to change icons of executable files tell me. Thanks!!
Summary:
1. First make a resource (.rc) file which refers to the icon like so: id ICON "path/to/my.ico"
2. Compile it into an object: windres my.rc -O coff -o my.res
3. Link it into your exe with the rest of your project: g++ -o my_app obj1.o obj2.o my.res
Since this uses command-line build-commands instead of using the codeblocks interface, try this:
1. Add your .rc file to your project, then right-click on the file and select "Properties".
2. Go to "advanced"
3. Select "use customer command to build this file"
4. Add windres my.rc -O coff -o $object
I have stated above that am new to programming teaching myself, am now on the chapters of function. Your code above is hard for me to understand. ( I think it needs the knowledge of classes and objects ) any ways thanks a lot for your help am sure your code works fine. It is my stupidity that makes your answer not useful. And Duoas I will try the resource hacker tool
If you're just learning functions, then you don't want to move to resources just yet. Be patient! You're probably not stupid. We were all learning functions at some point.