Click here to Skip to main content
15,893,588 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
source page code as follows


ASP.NET
<%@ Page Language="C#" MasterPageFile="~/OnlineExamFeedBack/MasterPage.master" AutoEventWireup="true"
    CodeFile="Feed_Back.aspx.cs" Inherits="OnlineExamFeedBack_Feed_Back" %>
    <%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

  
    <style type ="text/css">
     body
    {
    background-color:White;
    }
        .modalBackground
        {
            background-color: Gray;
            filter: alpha(opacity=50);
            opacity: 0.7;
        }
        
          .tdHeader
        {
            background-image: linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -o-linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -moz-linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -webkit-linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -ms-linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -webkit-gradient(	linear,	left bottom, left top,color-stop(0, rgb(240,216,216)),
	            color-stop(1, rgb(77,10,10)));
        }
    
    </style>
  

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div style="width: 253px">
        <table style="width: 835px">
            <tr>
                <td>
                    <asp:Label ID="Label12" runat="server" Text="Course" Font-Bold="True" ForeColor="Blue">
                </td>
            </tr>
            <tr>
                <td class="style1">
                    <asp:Label ID="Label1" runat="server" Text="To What extent was this course useful"
                        Font-Bold="True">
                </td>
                <td style="width: 138px">
                    <asp:DropDownList ID="ddlcourse" AutoPostBack="true" runat="server" 
                        Width="160px" onselectedindexchanged="ddlcourse_SelectedIndexChanged">
                    
                    <br />
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" InitialValue="--Select Grading--"
                        ControlToValidate="ddlcourse" ErrorMessage="Select the Grading" Font-Bold="True"
                        ForeColor="Red">
                </td>
            </tr>
            <tr>
                <td class="style1">
                    <asp:Label ID="Label2" runat="server" Text="To What extent you acquired sufficient skills"
                        Font-Bold="True">
                </td>
                <td style="width: 138px">
                    <asp:DropDownList ID="ddlcourseacquired" AutoPostBack="true" runat="server" Width="160px">
                    
                    <br />
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" InitialValue="--Select Grading--"
                        ControlToValidate="ddlcourseacquired" ErrorMessage="Select the Grading" Font-Bold="True"
                        ForeColor="Red">
                </td>
            </tr>
            <tr>
                <td class="style1">
                    <asp:Label ID="Label3" runat="server" Text="To What extent you gained confidence to use the actual equipments on board"
                        Font-Bold="True">
                </td>
                <td style="width: 138px">
                    <asp:DropDownList ID="ddlcoursegained" AutoPostBack="true" runat="server" Width="160px">
                    
                    <br />
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" InitialValue="--Select Grading--"
                        ControlToValidate="ddlcoursegained" ErrorMessage="Select the Grading" Font-Bold="True"
                        ForeColor="Red">
                </td>
            </tr>
        </table>
    </div>





when i run error as follows

The page contains markup that is not valid when attached to a master page

please help me what is the problem in my above source page code

Regards,
Narasiman P.
Posted
Updated 30-Oct-13 20:59pm
v2
Comments
Zafar Sultan 31-Oct-13 3:00am    
Have you closed your content tag? </asp:Content> is missing.

Replace your code with this
--------------------------------------
XML
<%@ Page Language="C#" MasterPageFile="~/OnlineExamFeedBack/MasterPage.master" AutoEventWireup="true"
    CodeFile="Feed_Back.aspx.cs" Inherits="OnlineExamFeedBack.Feed_Back" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <style type="text/css">
        body
        {
            background-color: White;
        }
        .modalBackground
        {
            background-color: Gray;
            filter: alpha(opacity=50);
            opacity: 0.7;
        }
        .tdHeader
        {
            background-image: linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -o-linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -moz-linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -webkit-linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -ms-linear-gradient(bottom, rgb(240,216,216) 0%, rgb(77,10,10) 100%);
            background-image: -webkit-gradient( linear, left bottom, left top,color-stop(0, rgb(240,216,216)), color-stop(1, rgb(77,10,10)));
        }
    </style>
    <div style="width: 253px">
        <table style="width: 835px">
            <tr>
                <td>
                    <asp:Label ID="Label12" runat="server" Text="Course" Font-Bold="True" ForeColor="Blue"></asp:Label>
                </td>
            </tr>
            <tr>
                <td class="style1">
                    <asp:Label ID="Label1" runat="server" Text="To What extent was this course useful"
                        Font-Bold="True"></asp:Label>
                </td>
                <td style="width: 138px">
                    <asp:DropDownList ID="ddlcourse" AutoPostBack="true" runat="server" Width="160px"
                        OnSelectedIndexChanged="ddlcourse_SelectedIndexChanged">
                    </asp:DropDownList>
                    <br />
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" InitialValue="--Select Grading--"
                        ControlToValidate="ddlcourse" ErrorMessage="Select the Grading" Font-Bold="True"
                        ForeColor="Red"></asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td class="style1">
                    <asp:Label ID="Label2" runat="server" Text="To What extent you acquired sufficient skills"
                        Font-Bold="True"></asp:Label>
                </td>
                <td style="width: 138px">
                    <asp:DropDownList ID="ddlcourseacquired" AutoPostBack="true" runat="server" Width="160px">
                    </asp:DropDownList>
                    <br />
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" InitialValue="--Select Grading--"
                        ControlToValidate="ddlcourseacquired" ErrorMessage="Select the Grading" Font-Bold="True"
                        ForeColor="Red">
                    </asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td class="style1">
                    <asp:Label ID="Label3" runat="server" Text="To What extent you gained confidence to use the actual equipments on board"
                        Font-Bold="True"></asp:Label>
                </td>
                <td style="width: 138px">
                    <asp:DropDownList ID="ddlcoursegained" AutoPostBack="true" runat="server" Width="160px">
                    </asp:DropDownList>
                    <br />
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" InitialValue="--Select Grading--"
                        ControlToValidate="ddlcoursegained" ErrorMessage="Select the Grading" Font-Bold="True"
                        ForeColor="Red"></asp:RequiredFieldValidator>
                </td>
            </tr>
        </table>
    </div>
</asp:Content>
 
Share this answer
 
Refer Below Links:
Link 1 [^]
Link 2 [^]
Link 3 [^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900