how to replace icon resource from ico file.
-
Now I can replace icon resource in a .exe file from other .exe file. I copy code from MSDN about UpdateResource. But I can not update icon resource from a icon file.
-
Now I can replace icon resource in a .exe file from other .exe file. I copy code from MSDN about UpdateResource. But I can not update icon resource from a icon file.
In almost the same way. When copying from one EXE to another, you used
LoadImage()
/LoadResource()
followed byLockResource()
to get a pointer to the icon's data. You then calledUpdateResource()
with that pointer. When using an ICO file, the only difference is to useCreateFile()
to open the ICO file, followed byReadFile()
to get a pointer to pass toUpdateResource()
. Make sense?
Five birds are sitting on a fence. Three of them decide to fly off. How many are left?