分析器错误消息'(默认)'不是属性'culture'的有效值

时间:2013-03-26 17:29:59

标签: asp.net telerik

分析程序错误说明:解析为此请求提供服务所需的资源时发生错误。请查看以下特定的解析错误详细信息并相应地修改源文件。

  

分析器错误消息:'(默认)'不是属性'culture'的有效值。

     

来源错误:

     

第1行:<%@ Page Language =“C#”AutoEventWireup =“true”CodeBehind =“HomePage.aspx.cs”Inherits =“FundingWebsiteAspnet.HomePage”第2行:MasterPageFile =“MasterPageForTheFundingWebsite.master”Culture =“ (默认)“%>第3行:

     

源文件:/HomePage.aspx行:1

     

此错误消息警告1 C:\ Users \ shussain2 \ Documents \ CTRP \ FundingWebsiteAspnet \ FundingWebsiteAspnet \ HomePage.aspx:ASP.NET运行时错误:无法加载文件或程序集'Telerik.Web.UI,Version = 2013.1。 220.40,Culture = neutral,PublicKeyToken = 121fae78165ba3d4'或其依赖项之一。定位的程序集的清单定义与程序集引用不匹配。 (来自HRESULT的异常:0x80131040)C:\ Users \ shussain2 \ Documents \ CTRP \ FundingWebsiteAspnet \ FundingWebsiteAspnet \ HomePage.aspx 1 1 CTRP

我该怎么做才能解决这个问题?我有想法降级但我希望新控件与它兼容。

代码HOMEPAGE.aspx

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="HomePage.aspx.cs" Inherits="FundingWebsiteAspnet.HomePage"
    MasterPageFile="MasterPageForTheFundingWebsite.master" 
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<asp:Content ID="mainContent" ContentPlaceHolderID="mainContentPlaceholder" runat="server">
    <head>
        <link rel="stylesheet" type="text/css" href="StyleSheetForTheFundingWebsite.css" />
        <style type="text/css">
            .modalBackground
            {
                background-color: Gray;
                filter: alpha(opacity=70);
                opacity: 0.7;
                border: 5px
                border-color: Black;
                border-style: solid;
            }
            .pnlBackGround
            {
                position: fixed;
                top: 10%;
                left: 10px;
                width: 650px;
                height: 300px;
                background-color: White;
                border: solid 3px black;
            }
        </style>
    </head>
    <form id="form1" runat="server">
    <cc1:ToolkitScriptManager ID="TKSM" EnablePageMethods="true" EnableCdn="true" ScriptMode="Release"
        runat="server">
    </cc1:ToolkitScriptManager>
    <asp:GridView ID="GridView1" runat="server" AllowPaging="False" AllowSorting="False"
        AutoGenerateColumns="False" AutoGenerateEditButton="False" CellPadding="4" 
        DataKeyNames="Study_Number" Width="100%" SkinID="Summary" OnRowCommand="grd_ReturnItems_RowCommand"
        DataSourceID="SqlDataSource1" ForeColor="#333333" GridLines="None" Height="236px"
        OnSelectedIndexChanged="GridView1_SelectedIndexChanged">
        <AlternatingRowStyle BackColor="White" />
        <Columns>
        <asp:TemplateField >
            <ItemTemplate>
                <asp:LinkButton ID="LinkButton1" runat="server" >Edit</asp:LinkButton>
            </ItemTemplate>
        </asp:TemplateField>
            <asp:CommandField EditText="Vaishali" />
            <asp:BoundField DataField="PI" HeaderText="PI" SortExpression="PI" />
            <asp:BoundField DataField="Study_Number" HeaderText="Study_Number" ReadOnly="True"
                SortExpression="Study_Number" />
            <asp:BoundField DataField="Study_Title" HeaderText="Study_Title" SortExpression="Study_Title" />
            <asp:BoundField DataField="Disease_Code" HeaderText="Disease_Code" SortExpression="Disease_Code" />
        </Columns>
        <FooterStyle BackColor="#990000" Font-Bold="True" ForeColor="White" />
        <HeaderStyle BackColor="#990000" Font-Bold="True" ForeColor="White" />
        <PagerStyle BackColor="#FFCC66" ForeColor="#333333" HorizontalAlign="Center" />
        <RowStyle BackColor="#FFFBD6" ForeColor="#333333" />
        <SelectedRowStyle BackColor="#FFCC66" Font-Bold="True" ForeColor="Navy" />
        <SortedAscendingCellStyle BackColor="#FDF5AC" />
        <SortedAscendingHeaderStyle BackColor="#4D0000" />
        <SortedDescendingCellStyle BackColor="#FCF6C0" />
        <SortedDescendingHeaderStyle BackColor="#820000" />
    </asp:GridView>
    <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:adm_productionConnectionString %>"
        SelectCommand="SELECT [PI], [Study Number] AS Study_Number, [Study Title] AS Study_Title, [Disease Code] AS Disease_Code FROM [Study_Disease_Code_association]">
    </asp:SqlDataSource>
    <cc1:ModalPopupExtender ID="mpe_EditReturnItemPopup" runat="server" TargetControlID="btn_Hidden1"
        PopupControlID="EditReturnItemDialog" BackgroundCssClass="modalBackground" CancelControlID="btn_EditReturnItemCancel"
        DropShadow="false" PopupDragHandleControlID="EditReturnItemDialogHeader" OkControlID="btnOk"
        X="20" Y="100" />
    <asp:Panel ID="EditReturnItemDialog" runat="server" Style="display: none; width: 300px"
        CssClass="pnlBackGround">

        <br />
        Please Enter Disease Code :
        <table>
            <tr>
                <td>
                    <br />
                    Select Disease Code Type:
                    <telerik:RadDropDownList ID="radDropDownDiseaseType" runat="server">
                    </telerik:RadDropDownList>
                </td>
            </tr>
            <tr>
                <td>
                    <br />
                    Select sub-category :
                    <telerik:RadDropDownList ID="radDropDownSubCat" runat="server">
                    </telerik:RadDropDownList>
                </td>
            </tr>
              <tr>
                <td>

                    Enter Meddra Code :
                   <telerik:RadDropDownList ID="radDropDownMeddra" runat="server">
                    </telerik:RadDropDownList>

                </td>
            </tr>
           <tr>
           <td>

           <asp:Button ID="btn_SaveEditReturnItem" runat="server" Text="Submit" OnClick="btn_SaveEditReturnItem_Click" />&nbsp;&nbsp;&nbsp;
            <asp:Button ID="btn_EditReturnItemCancel" runat="server" Text="Cancel" />
            <br />
            <br />
            <br />
           </td>
           </tr>
                      <tr>
           <td>
            <br />
            <br />
            <br />
           </td>
           </tr>
        </table>
        <br />
        <br />
        <center>
            </center>
        <asp:Button ID="btn_Hidden1" runat="server" Style="display: none" />
    </asp:Panel>
    </form>
</asp:Content>

1 个答案:

答案 0 :(得分:1)

从aspx页面删除Culture="(Default)"

从aspx页面删除<%@ Register TagPrefix="telerik" .... %>

将telerik命名空间放在web.config中。

<system.web>
    ...
    <pages>
      <controls>
        ...
        <add tagPrefix="telerik" namespace="Telerik.Web.UI" 
           assembly="Telerik.Web.UI"/>
        ...
      </controls>
    </pages>
    ...
</system.web>