You create an ASP.NET Web application project, and then
you deploy the project on another computer. When you try to open the deployed
project, you may receive the following error message:
The project you are trying to open is a Web project. You need
to open it by specifying its URL path.
To work around this problem, use any of the following
methods. For more information about each of these methods, click the method to view the procedure.
Deploy the project by using the same virtual directory name
When you deploy the project by using Microsoft Windows
Installer, change the name of the virtual directory of the project to be the same
as the name of the virtual directory of the original project (Project1). By
default, the virtual directory name that the Setup wizard provides is the name of
the Web Setup project (WebSetupProject1).
After you deploy the project by using a Web Setup project,
rename the Webinfo file and the project files to map to the virtual directory
of the project. To do this, follow these steps:
In Microsoft Windows Explorer, locate to the
C:\Inetpub\wwwroot\WebSetupProject1 folder.
Rename the following file, depending on your project:
If you are using Microsoft Visual C# .NET or Microsoft Visual C# 2005, rename the
Project1.csproj.webinfo file to WebSetupProject1.csproj.webinfo.
If you are
using Microsoft Visual Basic .NET or Microsoft Visual Basic 2005, rename the Project1.vbproj.webinfo file to
WebSetupProject1.vbproj.webinfo.
Rename the following file, depending on your project:
If you are using Visual C# .NET or Visual C# 2005, rename the Project1.csproj
file to WebSetupProject1.csproj.
If you are using Visual Basic .NET or Visual Basic 2005, rename the
Project1.vbproj file to WebSetupProject1.vbproj.
Use Visual C# .NET or Visual C# 2005 or use Visual Basic .NET or Visual Basic 2005
to create an ASP.NET Web Application project. Name the project
Project1.
Note In Visual Studio 2005, create an ASP.NET Web Site project.
For more information, click the following article numbers to view the articles in the Microsoft Knowledge Base:
326495
(http://support.microsoft.com/kb/326495/
)
How to move your Visual Studio .NET Web project to another computer
822316
(http://support.microsoft.com/kb/822316/
)
How to create a new ASP.NET Web application on a remote Web server
827028
(http://support.microsoft.com/kb/827028/
)
PRB: Error message when you try to run a Web Setup project that was created by using Visual Studio .NET
For more information, visit the following
Microsoft Developer Network (MSDN) Web sites: