When we writeProgramI may need to use system icons such as my computer. How can I obtain these icons for my use?
After searching over the Internet, it is found that most files are extracticonex, such as assumer.exe, shell32.dll, and so on. However, the positions (sequence) of these file icons may not necessarily remain the same for the operating system.
Then I suddenly found out that since these icons are available when implementing the directory tree, isn't this method more direct?
The general process is as follows: first use getsystemimagelist to obtain the system image list handle, then use shgetspecialfolderlocation to obtain the pidl of these system virtual folders, and then use shgetfileinfo to obtain a shfileinfo structure based on the shgfi_sysiconindex mark transmitted. iicon is what we need. To use these icons, use imagelist_geticon.
I personally think this method is the most concise and clear. Welcome to the discussion.