Is there any way to copy an entire Visual C# solution in such a way that it works? If you just copy it and rename it, it gives an error message that it's been renamed and therefore it refuses to work.

Recommended Answers

All 4 Replies

i couldnt find a way to do that, you can get around by creating and empty solution and adding your projects to that solution as existing projects.

serkan sendur:

Have you actually tried this? I would have to give the new solution a different name than the old one, and then the name of the copied project would be different than the solution that it's in, and I don't think that would work. If I changed the name of the copied project, I'd be right back to the same problem of having a project with its name changed, so that VC# consequently refuses to run it.

i tried what i suggested. i think "copying a solution" is ambigious, do you mean copying the solution file to another location, or all the project files ,with solution file included, to another location?

I meant copying the folder, with all its contents, for the entire solution. This folder contains the .sln & .suo files and the project folder. Such folders are subfolders of C:\Documents and Settings\Bob Lewiston\My Documents\Visual Studio 2008\Projects.
The copy of the solution folder is given a new name and also placed in C:\Documents and Settings\Bob Lewiston\My Documents\Visual Studio 2008\Projects.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.