2011-05-20 82 views
0

我使用visual studio 2008 fo rasp .net 3.5 web開發。我發佈了網站,並在windows xp中建立的IIS 5.1中添加了虛擬目錄。如何在IIS 5.1上發佈ASP.NET 3.5?

當我運行該頁面時,顯示以下錯誤。

The XML page cannot be displayed 
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later. 

A name was started with an invalid character. Error processing resource 'http://localhost/cdt/Dashboard.aspx'. Line 1, Pos... 

<%@ page language="C#" MasterPageFile="~/MasterPage.master" autoeventwireup="true" inherits="_Default, App_Web_zy4yhpyn" ... 

我需要另外安裝嗎?

爲什麼會發生這種情況?

解決方案是什麼?

更新:選擇.net 2.0版本。 (沒有選項,如3.5 IIS 5.1)

再次,現在跑了得到這個錯誤(我應該安裝一個更高版本): Failed to access IIS metabase. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.Hosting.HostingEnvironmentException: Failed to access IIS metabase.

編輯: 確定。我發現了錯誤。

在http://csharpdotnetfreak.blogspot.com/2009/02/failed-to-access-iis-metabase.html

大通過重新安裝ASP解決它!

+0

爲什麼IIS 5.1?你爲什麼不使用7+? – Shoban 2011-05-20 11:00:08

+0

因爲它是預先安裝在Windows XP中 – Ranjanmano 2011-05-20 11:16:48

回答

1

由於某些原因aspx文件無法正確呈現。嘗試使用ASP.NET IIS註冊工具(Aspnet_regiis.exe u-卸載,i-install)再次註冊asp.net。還要檢查IIS中的asp.net版本。

+0

我應該執行ID DOS?它不能在DOS – Ranjanmano 2011-05-20 11:12:09

+0

中識別,因此必須在Visual Studio命令提示符下運行.http://msdn.microsoft.com/en-us/library/k6h9cz8h(v = VS.90).aspx – Aravind 2011-05-20 11:17:39

+0

對不起。這是在命令窗口中執行的嗎? – Ranjanmano 2011-05-20 11:25:47