You're right; the question is clearly not a duplicate. Like you said, the other question is about .NET, rather than unmanaged C++. That's completely different. I'm not sure why you're so fixated on proving that it's not a duplicate. I only see one person who even mentioned that, a comment by PredragDj:
Your question will be closed because it is copy. Try answers from that link and edit question if you want to say that you did and it didn't work.
This commenter was wrong. Feel free to ignore this comment. In fact, I'll have deleted it from under your question by the time you read this answer.
However, there are other reasons than "duplicate" that questions get closed on Stack Overflow. Yours was never closed for being a duplicate. It was closed for lacking a minimal, reproducible example:
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
This reason is lumped under the broad category of "not suitable for this site", but, as you can see, there's a bit more nuance to it than that. You're supposed to be seeing this detailed explanation in the big blue banner.
Regardless of how much research you did, we cannot help you unless we can see your actual code. You say:
My icon is loaded into my resource file, and properly called in WinMain.
Are we just supposed to trust you on this? Assume that, even though you can't get it to work, you're doing everything correctly? I don't mean that to sound rude. Anyone who is not getting the results they expect to be getting needs to go back and re-evaluate their assumptions. Nobody ever said programming was easy. Mistakes happen all the time; that's why we ask for help. You increase the odds of getting good help if you give others all the information they need to replicate your problem.
Not to toot my own horn, but I'm something of an expert on Windows application development in C++ using Visual Studio. As your question currently stands, there's almost no way that I could help you if I wanted to. About the only thing I could do in terms of "answering" would be to post a tutorial on how to create a Win32 application with an icon. There's no guarantee that'll even help you—maybe you're already doing everything you should be doing already and there is some other problem—and, even if it would, that's simply not how Stack Overflow is supposed to work. This isn't a tutorial site; it's a Q&A site. You ask a specific question, and you get a specific answer. If there's not enough information provided in the question to enable a specific, complete answer, then the question ends up closed.
Since your particular issue is a visual one, it would probably also be helpful to include a screenshot, in addition to code. When you say "icon to appear in the taskbar", I cannot tell if you mean that the entire window doesn't appear as a button in the Windows taskbar (since the default view for Windows taskbars is showing only the icon on the button), or if you mean that the button is there for your window but simply lacking an icon. And which icon does it show—no icon? the "default" icon? a corrupted version of your icon?
(I just noticed you said that you don't have the necessary privileges to post images. We actually just don't let brand-new users post inline images. You can still upload the image to a service like Imgur—which is what we use as our image host—and include a link to it.)
We also need to know details about your icon, especially, what size is it? I see in a comment above that you indicated you're using LoadIcon
to load the icon. That's a good start—I wouldn't have known that just by reading your question, and that's a problem, because all detail needs to be in your question. But even knowing that, I still don't know enough to solve your problem. All I can do is guess—and Stack Overflow doesn't deal in guesses. What is my guess? LoadIcon
only supports "large" icons in the system-default size, typically 32×32 pixels. If you've designed an icon that is smaller or larger than that, LoadIcon
will probably refuse to load it. Are you checking the return value of LoadIcon
for failure? If you'd posted a minimal, reproducible example, I could run it and check for myself. Otherwise, you have to give us this detail.
In sum: your question is clearly not a duplicate, but it is rightly closed, and for the correct reason: lacks debugging details. If you add these details in, your question can be re-opened and answered.
wndclass.hIcon = LoadIcon(NULL, MAKEINTRESOURCE(IDI_ICON1));
The icon ID macro was automatically generated in the resource (.rc) file and resource header.