Solved

Visual Studio Express 2012: How to rename a Project?

Posted on 2013-10-27
4
1,829 Views
Last Modified: 2013-10-27
Hi Experts,
I had no problem renaming my Solution, just right-clicked on the solution name and chose the "rename" option from the context menu.

But when I right-click on the Project name, the "rename" option does not appear.

Is it possible to rename a Project in Visual Studio Express 2012?

thanks!
0
Comment
Question by:rascal
  • 2
  • 2
4 Comments
 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 39603903
Yes, you can rename a project in the manner you describe. Make sure your application is not actually running, though. If you are actively debugging your application, then you cannot make changes to it.
0
 
LVL 1

Author Comment

by:rascal
ID: 39603917
I closed VS, then re-opened it, made sure the debugger was not running, same result - the rename option does not appear when I right-click on the project name.

Screenshot1 shows the lack of the rename option in the popup menu.
Screenshot2 shows the debugger is not running
screenshot1.jpg
screenshot2.jpg
0
 
LVL 75

Accepted Solution

by:
käµfm³d   👽 earned 500 total points
ID: 39603975
Ah, you have a website, not a web application. Unfortunately, I don't think there is any way within Visual Studio to rename such (hopefully someone can chime in otherwise). As a workaround, you can manually edit the solution file (.sln)--it's just a text file. To do so:

Make a backup!!
Close VS
Navigate to the folder that has your project
Open the .sln file within a text editor
Replace all occurrences of your website name ("ccr") with the new name
Save and close the file
Open up your solution's directory
Rename the .sln and the .suo file to more appropriate names
Go up one level
Rename the website folder
Go up two levels. You should be in the Visual Studio folder
Go in to the "WebSites" folder
Rename your website's folder
Open up the IIS Express Application Host file. Within your Documents folder (standard Windows folder), there should be a folder named "IISExpress". Within that folder is a folder named "config". Within that folder is a file named "applicationhost.config". It is simply an XML file. Open it up within a text editor, and rename the occurrence of your old website name with the new website name. Also change the path to point to the new path.
Reopen your poject within VS (old name won't work, so don't try to open it from the Start Page listing. You'll need to browse to the new .sln file.
0
 
LVL 1

Author Closing Comment

by:rascal
ID: 39604037
Thanks kaufmed for the excellent answer.
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Here is a helpful source code for C++ Builder programmers that allows you to manage and manipulate HTML content from C++ code, while also handling HTML events like onclick, onmouseover, ... Some objects defined and used in this source include: …
Jaspersoft Studio is a plugin for Eclipse that lets you create reports from a datasource.  In this article, we'll go over creating a report from a default template and setting up a datasource that connects to your database.
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
THe viewer will learn how to use NetBeans IDE 8.0 for Windows to perform CRUD operations on a MySql database.

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question