What is the best way to copy or cut/paste a form from one project to another project within a Solution in Visual Studio?
Whenever I try it, using the solution explorer (drag and drop or right clicking cut and paste), it only copies the underlying C# code and not the necessary ‘bits and pieces’ that help you visualise the form via the form designer.
- Copy the three files,
resxto the target solution folder.
- In the target project, select
Add existing itemand add the designer file first.
- Modify the Namespace attribute. The
.csfile should come in as well.
- Modify the namespace in the
- Add the
Add existing item.