Click here to Skip to main content
15,898,222 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Before I make a major change in my C# project Project1, I want to save the Project1 as Project2. Can it create some conflict between Project1 and Project2? For example, I see the following names on IDE:
Testing (with file name Testing.cs in the file system)
Program (with file name Program.cs2.cs in the file system)

It is a simple application: It generates random numbers, does some number crunching and displays an output in about 100 lines using Debug statement.)

What precautions should I take regarding the names Testing,Program and any other names?

Thank you.

Sohan Jain
Posted
Updated 24-Jun-12 12:09pm
v2
Comments
Member 9164478 25-Jun-12 14:36pm    
The solution #1 does not solve my problem. How about this: If I create a new project as Project2 and copy the entire code from Project1?

Sohan Jain

1 solution

This is nothing like a clone, this is a "shallow copy". The source and destination projects will be in a permanent conflict because they actually share the same source code files. The whole idea of copy project suggests the lack of design with code re-used (it looks like per your explanation); you don't need to use code but need to put code in libraries, use them in different projects, etc. However, cloning projects is sometimes needed for re-factorization of code and other similar purposes. First of all, you need to know exactly what is your source code and what are the temporary files, output, and other non-source artifacts. This is very important for programming to know the purpose of every artifact of programming in the form of file. You also should be able to remove all unused artifacts of project templates: unused resource, configuration files, etc., and, importantly, unused references. If you know all that, the cloning is simple: you remove all temporary files and copy a whole project directory to a new location.

—SA
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900