Exclude .cs from project through code? (Visual Studio)
<p>I need to exclude .cs files from project through code, for example with T4 template. I know that you can modify the .csproj file, but this doesn't work properly if the project is opened with Visual Studio, so is there any way to exclude/add .cs files through code(for example, with T4 templates)?</p>

<p>Thanks</p>
