开发者

Visual Studio 2008 - Open Website from Local IIS problems

开发者 https://www.devze.com 2022-12-16 12:15 出处:网络
I\'ve spent a great long while googling this problem without any luck and I\'ve always found great answers here, so here it goes:

I've spent a great long while googling this problem without any luck and I've always found great answers here, so here it goes:

[BACKGROUND]

I have a web application which was developed in C# with Visual Studio 2008. It was a part of a solution with another project which contained a web service. 开发者_C百科This was not created "IN" IIS (I was using the Cassini ASP.NET Development Server at first, but have encountered numerous issues). I finally got approval to install IIS 5.1 (Government Network - using Windows XP) so I wanted to host my apps there for development.

I moved my projects to another folder created my IIS virtual directories, pointed them at the right location, updated my security settings, ensured that .NET 2.0 was selected and tested the site and web service. They function perfectly in IIS.

[ACTUAL PROBLEM]

I open Visual Studio, click File > Open > Web Site > Local IIS > [Application Name] and it opens up, but my .design files aren't nested under the ASPX / ASCX objects, and when I right click on it and select "View Code" it takes me to the markup instead of the code behind. Once I reach the code behind, I don't have access to any of the members of the design, as though there was a problem with the wire up.

I have tried creating a web site from IIS through Visual Studio, and it works perfectly. I closed it and opened it up again to see if that functionality would persist and it did.

I've encountered this before and have had to re-create a new site through Visual Studio, and manually re-populate it with all of my classes from a "broken" solution. I would love to solve this the correct way.

Please help!

Adam


The best thing I could suggest would be to go through the Project files with a fine toothcomb (as Filburt suggested) and make sure the references are pointing to a virutal directory (or via the inetpub folder, if thats how your IIS settings are configured), rather than a file system directory.

You might also want to check your IIS settings. Is your virutal directory set up to point to a file directory?

Good luck!


All dependencies between markup, .design and code-behind files are laid out in the project file. You could use a sample project to discover how to correct your existing project.

0

精彩评论

暂无评论...
验证码 换一张
取 消