I have a Blank Forms project in C#.
I wanted to separate the functions and events into different Codefiles on the Form Class. In order to make it more manageable when it becomes large and multiple people are using it on CodeControl.
So I created;
Form1.Functions.csForm1.Events.cs
These extra partial classes both consist of
namespace MyLargeProject
{
public partial class Form1
{
}
}
I also changed the csproj file so the VS IDE would make them appear in the Soution Explorer.
Example
<Compile Include="Forms\Form1.Functions.cs">
<DependentUpon>Form1.cs</DependentUpon>
<SubType>Form</SubType>
</Compile>
So the program compiles and all is looking good except that when I open the file from the solution explorer it opens up a blank Form designer, and not the code.
I want VS to only open this class as a code file to limit issues with the Form1.Designer.cs file.
I have also tried removing the SubType
<SubType>Form</SubType>
but Visual Studio keeps adding it back to the csproj file.