Now you are adding a thread to coding questions, but answering it yourself in the first post?
I think you can guess. I post a question that I previously tested in my program for an hour, or maybe more, using different methods. I understand that I can’t do it and the search doesn’t give results, so I ask a question. But at the same time, why do you think that I should stop? I change the search methods, use the Google query "ico site:purebasic.fr/english" and look through 5 pages of results and finally I found the function. Of course, I try to save you from useless work by posting useful results. This function had just worked for me and I wanted to post the code using this function, but something broke again. Initially, I changed 24 to 32 and the function began to work. And now I'm reviewing the code in which I changed almost nothing and trying to understand why it doesn't work.
The function uses an icon descriptor, and I give it an image descriptor. So I haven't gotten the perfect answer yet and am tweaking the image to make it look like an icon handle.
Some of your applications are in General Discussion, why? (=> "Applications - Feedback and Discussion"?)
Some of your codes are in General Discussion, why? (=> "Tricks 'n' Tips"?)
What year is the message from? Previously, I posted it in the discussion section, but I was advised to post it in the applications section, since I am giving a ready-made application. On the other hand, the source code is not posted in the applications section, but only the executable file. In this case, my source code is more suitable for the “Tricks 'n' Tips” section. Attention, question, if you have a logic for where to put it, then just express it, but don’t make me guess your thoughts, I acted based on my understanding.
By the way, the "Tricks 'n' Tips" section is a bit of an unusual name to put the functionality in the section, perhaps this is a translation problem into Russian.
This code does not allow you to create an icon from an image
Code: Select all
If Not GetIconInfo_(hIcon, iconinfo)
Debug 1
ProcedureReturn 0
EndIf ; Not a valid icon handle.