我在 Delphi Prism 中编写了一个 ASP.NET Web 应用程序(不是网站)。在我的开发机器上一切正常,但是当我将其安装在测试服务器上时,出现以下错误:
Server Error in '/MyApp' Application.
Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.
Parser Error Message: 'Oxygene' is not a supported language.
Source Error:
Line 1: <%@ Application CodeBehind="Global.asax.pas" Inherits="MyApp.Global_asax" Language="Oxygene" %>
Source File: /MyApp/global.asax Line: 1
我已经阅读了网上能找到的所有内容。有几篇文章提到了 RemObjects 页面 (http://devcenter.remobjects.com/articles/?id={B549AFB8-04C8-4574-B185-30DE14369E66}),不幸的是,该页面已不存在。
一些链接建议您只需将 Language="Oxygene" 更改为 Language="C#"。尝试这个会产生不同的错误:
Compiler Error Message: CS1061: 'ASP.login_aspx' does not contain a definition for 'ForgottenUsernameLinkButton_Click' and no extension method 'ForgottenUsernameLinkButton_Click' accepting a first argument of type 'ASP.login_aspx' could be found (are you missing a using directive or an assembly reference?)
还有其他人遇到过这些问题吗?
- 有几种方法可以解决这个问题。最简单的方法:如果您控制服务器是通过安装命令行版本。
- 另一种方法是预编译,它:你需要网络部署项目 http://www.microsoft.com/downloads/en/details.aspx?FamilyID=89F2C4F5-5D3A-49B6-BCAD-F776C6EDFA63去做这个。执行此操作时,请确保取消选中可更新选项。
- 在 2010 年 8 月的版本中,您可以将 .compiler、.codemodel、.pdb、.cirrus 复制到 Bin/,然后在您的 web.config 中添加如下内容:
<system.codedom>
<compilers>
<compiler language="Chrome" extension=".pas" type="RemObjects.Oxygene.CodeDom.OxygeneCodeProvider, RemObjects.Oxygene.CodeModel, Version=4.0.0.800, Culture=neutral, PublicKeyToken=3df3cad1b7aa5098" />
<compiler language="Oxygene" extension=".pas" type="RemObjects.Oxygene.CodeDom.OxygeneCodeProvider, RemObjects.Oxygene.CodeModel, Version=4.0.0.800, Culture=neutral, PublicKeyToken=3df3cad1b7aa5098" />
</compilers>
</system.codedom>
请注意,这要求版本号 (4.0.0.800) 必须与您拥有的 CodeModel dll 的 dll 版本相匹配。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)