Visual Studio adding an image to project

2019-01-31 23:29发布

Good Day

I am new to Visual Studio and I just added a folder to my project by right clicking on the project and adding a new folder. Now I added the image to the folder(copy paste in windows), but the solution explorer is not showing my added image...I did refresh the solution as well. Also, in that folder, there is no option of adding an image, only Visual Studio files(new items etc)..

Why isn't Solution Explorer showing my image?

4条回答
Melony?
2楼-- · 2019-01-31 23:41
  • You just need to have an existing file, open the context menu on your folder , and then choose Add => Existing item...

    enter image description here

  • If you have the file already placed within your project structure, but it is not yet included, you can do so by making them visible in the solution explorer

    enter image description here

and then include them via the file context menu enter image description here

查看更多
虎瘦雄心在
3楼-- · 2019-01-31 23:43

Click on the Project in Visual Studio and then click on the button titled "Show all files" on the Solution Explorer toolbar. That will show files that aren't in the project. Now you'll see that image, right click in it, and select "Include in project" and that will add the image to the project!

查看更多
Deceive 欺骗
4楼-- · 2019-01-31 23:51

You need to turn on Show All Files option on solution pane toolbar and include this file manually.

查看更多
一纸荒年 Trace。
5楼-- · 2019-01-31 23:59

If you're having an issue where the Resources added are images and are not getting copied to your build folder on compiling. You need to change the "Build Action" to None from Resource ( which is the default) and change the Copy to "If Newer" or "Always" as shown below :

enter image description here

查看更多
登录 后发表回答