Hi,
I am trying to teach myself C#.NET and am trying to create a blank page that uses a master page template.
My default.aspx page is as follows:
However I am getting an error message:
Parser Error Message: The 'CodeFile' attribute is not supported by the 'page' directive.
Source Error:
Line 1: <%@ Page Title="" Language="C#" MasterPageFile="~/dotnet/masterpages/MasterPage.master" AutoEventWireup="true" CodeFile="Default.aspx.cs" %>
Line 2:
Line 3: <asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
Source File: D:\Clients\dotnet\default.aspx Line: 1
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.2494; ASP.NET Version:1.1.4322.2494
Any ideas where I am going wrong?
Thanks very much
Ed
I am trying to teach myself C#.NET and am trying to create a blank page that uses a master page template.
My default.aspx page is as follows:
Code:
<%@ Page Title="" Language="C#" MasterPageFile="~/dotnet/masterpages/MasterPage.master" AutoEventWireup="true" CodeFile="Default.aspx.cs" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
</asp:Content>
However I am getting an error message:
Parser Error Message: The 'CodeFile' attribute is not supported by the 'page' directive.
Source Error:
Line 1: <%@ Page Title="" Language="C#" MasterPageFile="~/dotnet/masterpages/MasterPage.master" AutoEventWireup="true" CodeFile="Default.aspx.cs" %>
Line 2:
Line 3: <asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
Source File: D:\Clients\dotnet\default.aspx Line: 1
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.2494; ASP.NET Version:1.1.4322.2494
Any ideas where I am going wrong?
Thanks very much
Ed