Search code examples
visual-studiomsbuildprojects-and-solutions

Create virtual folder in Visual Studio 2012


Essentially I need a folder and its items available in the project for debugging but I don't want it included in the publish.


Solution

  • You can exclude folders from your build-Solution (by default Debug and Publish are available).

    • Right click in the solution explorer and Add New Folder. Name it.
    • Right click on the folder and choose 'Exclude from project'

    Excluding a Folder from a Project/Solution

    Note the screenshot is from VS2010 C# Express, but the same option is available in VS2012.