When we open a web or windows form file from the Solution Explorer window the designer is displayed for those forms. Sometimes it may be time consuming especially for large web forms that take a while to open.
There is an option on Visual Studio that defines how the files are opened when you double-click on them.
- Open Tools menu > Options;
- From the left tree view, select HTML Designer;
- On the right panel you will see the option “Start pages in”. You have three options:
- Design view (design only);
- Source view (html markup);
- Split view (design and html markup).
- Select the option that fits better on your needs and click ok.
There is no way to control how Windows Forms are opened via Options directly but there is a trick:
- Right-click a windows form file on the Solution Explorer window;
- From the context menu, select the option “Open With”;
- The Open With dialog is displayed;
- Select CSharp Editor;
- Click on Set as Default button;
- Click OK.