问题
I am having trouble importing an icon into my application. I have a main form and I am trying to import to it a new icon via the Icon
field in Properties
.
The image is already in .ico
format: this is the link to the icon I'm trying to use.
Does anyone know why Microsoft Visual Studio would be displaying this error?

Any help would be great.
回答1:
I had this error recently. Some recommendations:
- make sure the icon is square (16x16, 32x32)
- try saving it to a PNG and using this free service for conversion : http://www.convertico.com/
回答2:
We have an application that works fine on 99% of our computers, but in one laptop it pops out this error.
It looks like our issue is that the laptop user set the screen text/image size to 150%. This could cause otherwise working images no longer working. We will see whether this works.
UPDATE
A commenter seems to have the same problem. And yes, we resolved this problem by setting the screen text size to less than 150%.
回答3:
After a second restart and then opening and re-saving the .ico myself in Gimp, then I was able to import it without any errors. Not too sure what caused this problem but it was just a freak error.
来源:https://stackoverflow.com/questions/10333256/c-sharp-argument-picture-must-be-a-picture-that-can-be-used-as-an-icon