TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Abraham Olatubosun
NA
471
114.5k
Master Page not Showing Content Page
May 15 2017 6:26 PM
Dear code masters,
I havs a web application designed with asp:Masterpage with content page all works fine, i currently add another master page and disabled the previous one now i developed it with bootstrap but some content page didn't show when at run time even though i pointed all the content page to the new master page.
new masterpage html :
<%@ Master Language=
"C#"
AutoEventWireup=
"true"
CodeFile=
"MasterPage.master.cs"
Inherits=
"Admin_MasterPage"
%>
<%@ Register Assembly=
"AjaxControlToolkit"
Namespace=
"AjaxControlToolkit"
TagPrefix=
"asp"
%>
<!DOCTYPE html>
<html xmlns=
"http://www.w3.org/1999/xhtml"
>
<head runat=
"server"
>
<title>ECEWS LAEAVE APPLICATION</title>
<link href=
"Content/bootstrap.min.css"
rel=
"stylesheet"
type=
"text/css"
/>
<%--<meta charset=
"utf-8"
/>
<meta name=
"viewport"
content=
"width=device-width, initial-scale=1"
/>--%>
<asp:ContentPlaceHolder ID=
"head"
runat=
"server"
>
</asp:ContentPlaceHolder>
</head>
<body>
<form id=
"form1"
runat=
"server"
>
<asp:ScriptManager ID=
"ScriptManager1"
runat=
"server"
></asp:ScriptManager>
<div>
<div
class
=
"banner navbar navbar-fixed-top navbar-default"
role=
"banner"
>
<asp:Image ID=
"Image1"
runat=
"server"
Height=
"102px"
ImageUrl=
"~/image/E_Leave_Logo.png"
Width=
"68%"
/>
</div>
<nav
class
=
" navbar navbar-default navbar-fixed-top "
style=
"margin-top: 100px;"
>
<div
class
=
"navbar-header"
>
<button type=
"button"
class
=
" navbar-toggle"
data-toggle=
"collapse"
data-target=
"#tp"
>
<span
class
=
"icon-bar"
></span>
<span
class
=
"icon-bar"
></span>
<span
class
=
"icon-bar"
></span>
<span
class
=
"icon-bar"
></span>
</button>
</div>
<%--<div id=
"tp"
class
=
"navbar-collapse collapse"
>
<ul
class
=
"nav nav-tabs navbar-nav bg-success"
>
<li><a href=
"Default.aspx"
>Home</a></li>
<li
class
=
"dropdown"
>
<a href=
"#"
class
=
"dropdown-toggle"
data-toggle=
"dropdown"
>Personnel <b
class
=
"caret"
></b></a>
<ul
class
=
"dropdown-menu"
>
<li><a href=
"frmPersonnel.aspx"
>Personel Record</a></li>
</ul>
</li>
</ul>
</div>--%>
<div id=
"tp"
class
=
"navbar-collapse collapse "
>
<ul
class
=
"nav navbar-nav nav-tabs pull-right"
>
<li
class
=
"dropdown"
>
<a href=
"#"
class
=
"dropdown-toggle"
data-toggle=
"dropdown"
>Personnel <b
class
=
"caret"
></b></a>
<ul
class
=
"dropdown-menu"
>
<li><a href=
"Admin/frmPersonnel.aspx"
>Personel Record</a></li>
<li><a href=
"frmPensionAdmin.aspx"
>Pension Fund</a></li>
<li
class
=
"divider"
></li>
<li><a href=
"Admin/frmApproveLeave.aspx"
>Leave Approval</a></li>
<li><a href=
"Admin/frmLeavReport.aspx"
>Leave Report</a></li>
</ul>
</li>
<li
class
=
"dropdown"
>
<a href=
"#"
class
=
"dropdown-toggle"
data-toggle=
"dropdown"
>Entry Form <span
class
=
"caret"
></span>
<ul
class
=
"dropdown-menu"
>
<li><a href=
"Personnel/frmLeavesheet.aspx"
>Leave Application</a></li>
<li><a href=
"Personnel/Appraisal.aspx"
>Staff Performance</a></li>
</ul>
</a>
</li>
<li
class
=
"dropdown"
>
<a href=
"#"
class
=
"dropdown-toggle"
data-toggle=
"dropdown"
>Admin <span
class
=
"caret"
></span>
<ul
class
=
"dropdown-menu"
>
<li><a href=
"Admin/frmCreateUser.aspx"
>Create User </a></li>
<li><a href=
"Admin/frmChangepass.aspx"
>Change Password</a></li>
</ul>
</a>
</li>
<li><a href=
"#"
class
=
"glyphicon glyphicon-envelope"
>Contact</a></li>
<li><a href=
"#"
class
=
"glyphicon "
>About Us</a></li>
<li><a href=
"#"
class
=
"glyphicon "
>Login</a></li>
</ul>
</div>
</nav>
<asp:ContentPlaceHolder ID=
"ContentPlaceHolder1"
runat=
"server"
>
</asp:ContentPlaceHolder>
<footer
class
=
" navbar navbar-fixed-bottom bg-success"
>
<p
class
=
"text-center"
>Copyright ©2016</p>
</footer>
</div>
</form>
<script src=
"Scripts/jquery-1.9.1.min.js"
type=
"text/javascript"
></script>
<script src=
"Scripts/bootstrap.min.js"
type=
"text/javascript"
></script>
</body>
</html>
while content page html :
<%@ Page Title=
""
Language=
"C#"
MasterPageFile=
"~/Admin/MasterPage.master"
AutoEventWireup=
"true"
CodeFile=
"frmApproveLeave.aspx.cs"
Inherits=
"Admin_frmApproveLeave"
%>
<asp:Content ID=
"Content1"
ContentPlaceHolderID=
"head"
Runat=
"Server"
>
<style type=
"text/css"
>
.auto-style4 {
width: 100%;
}
.auto-style6 {
width: 364px;
}
.auto-style7 {
width: 662px;
}
.auto-style5 {
text-align: right;
}
.style1
{
width: 573px;
}
</style>
</asp:Content>
<asp:Content ID=
"Content2"
ContentPlaceHolderID=
"ContentPlaceHolder1"
Runat=
"Server"
>
<div style=
"margin-top:150px"
class
=
"row"
>
<div
class
=
"col-sm-2"
></div>
<div
class
=
"col-sm-8"
>
<div
class
=
" col-sm-12 bg-primary text-center"
>Leave Approval form</div>
<table
class
=
"table table-bordered auto-style4 table-condensed"
>
<tr >
<td style=
"text-align: right"
>
<asp:Label ID=
"Label1"
runat=
"server"
Text=
"Employee ID :"
></asp:Label>
</td>
<td >
<asp:TextBox ID=
"TextBox1"
runat=
"server"
></asp:TextBox>
<%-- <asp:Button ID=
"btnFind"
runat=
"server"
OnClick=
"btnFind_Click"
Text=
"Find"
/>--%>
<button type=
"submit"
id=
"btnFind"
runat=
"server"
onserverclick=
"btnFind_Click"
class
=
"btn btn-warning"
>Find <b
class
=
"glyphicon glyphicon-search"
></b></button>
<%-- <asp:Button ID=
"btnClear"
runat=
"server"
OnClick=
"btnClear_Click"
Text=
"Clear All"
/>--%>
<button type=
"submit"
id=
"btnClear"
runat=
"server"
onserverclick=
"btnClear_Click"
class
=
"btn btn-danger"
>Clear All <b
class
=
"glyphicon glyphicon-remove"
></b></button>
</td>
</tr>
<tr >
<td colspan=
"2"
>
<asp:GridView ID=
"GridView1"
runat=
"server"
AllowPaging=
"True"
AutoGenerateColumns=
"False"
BackColor=
"White"
BorderColor=
"#E7E7FF"
BorderStyle=
"Dotted"
BorderWidth=
"1px"
CellPadding=
"3"
DataKeyNames=
"num"
OnRowCommand=
"GridView1_RowCommand"
OnPageIndexChanging =
"GridView1_PageIndexChanging"
Width=
"100%"
>
<AlternatingRowStyle BackColor=
"#F7F7F7"
/>
<Columns>
<asp:BoundField DataField=
"employeeid"
HeaderText=
"Employee ID"
/>
<asp:BoundField DataField=
"startedate"
DataFormatString=
"{0:d}"
HeaderText=
"Start Date"
>
<ItemStyle HorizontalAlign=
"Center"
/>
</asp:BoundField>
<asp:BoundField DataField=
"stopdate"
DataFormatString=
"{0:d}"
HeaderText=
"End Date"
>
<ItemStyle HorizontalAlign=
"Center"
/>
</asp:BoundField>
<asp:BoundField DataField=
"nodays"
HeaderText=
"No. of Days"
>
<ItemStyle HorizontalAlign=
"Center"
/>
</asp:BoundField>
<asp:BoundField DataField=
"status"
HeaderText=
"Status"
>
<ItemStyle HorizontalAlign=
"Center"
/>
</asp:BoundField>
<asp:ButtonField CommandName=
"btnCmd"
HeaderText=
"Select"
Text=
"Select"
>
<ItemStyle Font-Bold=
"True"
Font-Italic=
"True"
HorizontalAlign=
"Center"
/>
</asp:ButtonField>
</Columns>
<EditRowStyle HorizontalAlign=
"Center"
/>
<FooterStyle BackColor=
"#B5C7DE"
ForeColor=
"#4A3C8C"
/>
<HeaderStyle BackColor=
"#4A3C8C"
Font-Bold=
"True"
ForeColor=
"#F7F7F7"
/>
<PagerSettings FirstPageText=
"First"
LastPageText=
"Last"
Mode=
"NextPreviousFirstLast"
NextPageText=
"Next"
PreviousPageText=
"Prev"
/>
<PagerStyle BackColor=
"#E7E7FF"
ForeColor=
"#4A3C8C"
HorizontalAlign=
"Right"
/>
<RowStyle BackColor=
"#E7E7FF"
ForeColor=
"#4A3C8C"
/>
<SelectedRowStyle BackColor=
"#738A9C"
Font-Bold=
"True"
ForeColor=
"#F7F7F7"
/>
<SortedAscendingCellStyle BackColor=
"#F4F4FD"
/>
<SortedAscendingHeaderStyle BackColor=
"#5A4C9D"
/>
<SortedDescendingCellStyle BackColor=
"#D8D8F0"
/>
<SortedDescendingHeaderStyle BackColor=
"#3E3277"
/>
</asp:GridView>
</td>
</tr>
<tr >
<td >
<asp:Label ID=
"Label2"
runat=
"server"
Text=
"Employee ID :"
></asp:Label>
</td>
<td >
<asp:TextBox ID=
"TextBox2"
runat=
"server"
></asp:TextBox>
</td>
</tr>
<tr >
<td >
<asp:Label ID=
"Label3"
runat=
"server"
Text=
"Requested Days :"
></asp:Label>
</td>
<td >
<asp:TextBox ID=
"TextBox3"
runat=
"server"
></asp:TextBox>
</td>
</tr>
<tr >
<td >
<asp:Label ID=
"Label4"
runat=
"server"
Text=
"Approved Days :"
></asp:Label>
</td>
<td >
<asp:TextBox ID=
"TextBox4"
runat=
"server"
></asp:TextBox>
<asp:CheckBox ID=
"CheckBox1"
runat=
"server"
Text=
"Approved ?"
TextAlign=
"Left"
/>
</td>
</tr>
<tr >
<td > </td>
<td >
<%--<asp:Button ID=
"Button1"
runat=
"server"
Text=
"Submit and Approved "
/>--%>
<button type=
"submit"
class
=
"btn btn-success"
id=
"btnSave"
runat=
"server"
onserverclick=
"btnSave_Click"
>Submit and Approved <b
class
=
"glyphicon glyphicon-ok"
></b></button>
</td>
</tr>
<tr >
<td > </td>
<td >
</td>
</tr>
<tr >
<td > </td>
<td >
</td>
</tr>
</table>
</div>
</div>
</asp:Content>
This content page is not showing with the master page.
Kindly advice me on what i am doing wrong.
Thank you all
Reply
Answers (
7
)
How we make SMS system in c# for desktop
i have a searching in database if record not found then mess