当前位置:编程学习 > C#/ASP.NET >>

警告 165 无法识别的命名空间“asp”。

使用了母板页,但是content中的内容不能识别asp是什么原因? --------------------编程问答-------------------- 页面代码如下:
<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="装备列表.aspx.cs" Inherits="装备列表" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <div>
        


        <br />
        <asp:GridView ID="GridView1" runat="server" AllowPaging="True" CellSpacing="1" 
            GridLines="None" PageSize="20" Font-Size="12px" 
            AutoGenerateColumns="False"
            OnRowDeleting="GridView1_RowDeleting" OnRowEditing="GridView1_RowEditing" 
            onpageindexchanging="GridView1_PageIndexChanging" AllowSorting="True" 
            onsorting="GridView1_Sorting" ShowFooter="True" DataKeyNames="FaciId" 
            onrowcancelingedit="GridView1_RowCancelingEdit" 
            onrowupdating="GridView1_RowUpdating" BorderStyle="Outset">
            <PagerSettings FirstPageText="第一页" LastPageText="最后一页" 
            NextPageText="下一页" PreviousPageText="上一页" />
            <HeaderStyle BackColor="#C6C3C6" Font-Size="12px" HorizontalAlign="Center" />
            <FooterStyle BackColor="#C6C3C6" ForeColor="black"/>
            <Columns>
            <asp:BoundField DataField="FaciId" HeaderText="装备编号" SortExpression="FaciId" 
            ItemStyle-HorizontalAlign="center"/>  
            <asp:BoundField DataField="FaciName" HeaderText="装备名称" SortExpression="FaciName"
            ItemStyle-HorizontalAlign="center"/>
            <asp:BoundField DataField="型号" HeaderText="型号" SortExpression="型号"
            ItemStyle-HorizontalAlign="center"/>
             <asp:BoundField DataField="ServeTime" HeaderText="使用年限" SortExpression="ServeTime"
            ItemStyle-HorizontalAlign="center"/>
            <asp:BoundField DataField="BeginTime" HeaderText="开始使用日期" SortExpression="BeginTime"
            ItemStyle-HorizontalAlign="center" DataFormatString="{0:yyyy-MM-dd}"/>
             <asp:BoundField DataField="SiteName" HeaderText="所属站点" SortExpression="SiteName"
            ItemStyle-HorizontalAlign="center" />
             <asp:BoundField DataField="SiteRoute" HeaderText="所属地铁线路" SortExpression="SiteRoute"
            ItemStyle-HorizontalAlign="center" />
            <asp:CommandField HeaderText="删除"  ShowDeleteButton="true" ItemStyle-HorizontalAlign="center" />
            <asp:CommandField HeaderText="修改信息"   EditText="编辑"
            ShowEditButton="true" ItemStyle-HorizontalAlign="center" />
            </Columns>
           
        </asp:GridView>
    
        <br />
        <br />
    </div>
</asp:Content>
补充:.NET技术 ,  ASP.NET
CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,