R
RAM
Hello,
I have created simple ASP.NET application with master page
MIMStock.master:
<%@ Master Language="C#" AutoEventWireup="true" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head" runat="server">
<title>MIM Stock</title>
<link rel="Stylesheet" type="text/css" href="Styles.css" />
</head>
<body class="WithBackground">
<asp:SiteMapDataSource ID="Map" runat="server"
ShowStartingNode="false" />
<asp:Menu ID="Menu" runat="server" DataSourceID="Map"
Orientation="Horizontal">
</asp:Menu>
<asp:SiteMapPath ID="Path" runat="server"
Font-Size="Smaller"
RootNodeStyle-ForeColor="Black"
NodeStyle-ForeColor="Black" />
<br />
<asp:ContentPlaceHolder ID="ContentPlaceHolder" runat="server"
/>
</body>
</html>
Then I use master page on Default.aspx:
<%@ Page Language="C#" MasterPageFile="~/MIMStock.master"
AutoEventWireup="true" CodeFile="Default.aspx.cs"
Inherits="DefaultPage" %>
<asp:Content ID="Content" ContentPlaceHolderID="ContentPlaceHolder"
runat="server">
<h2>Welcome!</h2>
</asp:Content>
This code generates error when entering page Default.aspx:
Message: Exception of type 'System.Web.HttpUnhandledException' was
thrown.
But after removing asp:Menu from MIMStock.master page is displayed
correctly.
Could you explain me please this phenomena?
I really need to use menu.
/RAM/
I have created simple ASP.NET application with master page
MIMStock.master:
<%@ Master Language="C#" AutoEventWireup="true" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head" runat="server">
<title>MIM Stock</title>
<link rel="Stylesheet" type="text/css" href="Styles.css" />
</head>
<body class="WithBackground">
<asp:SiteMapDataSource ID="Map" runat="server"
ShowStartingNode="false" />
<asp:Menu ID="Menu" runat="server" DataSourceID="Map"
Orientation="Horizontal">
</asp:Menu>
<asp:SiteMapPath ID="Path" runat="server"
Font-Size="Smaller"
RootNodeStyle-ForeColor="Black"
NodeStyle-ForeColor="Black" />
<br />
<asp:ContentPlaceHolder ID="ContentPlaceHolder" runat="server"
/>
</body>
</html>
Then I use master page on Default.aspx:
<%@ Page Language="C#" MasterPageFile="~/MIMStock.master"
AutoEventWireup="true" CodeFile="Default.aspx.cs"
Inherits="DefaultPage" %>
<asp:Content ID="Content" ContentPlaceHolderID="ContentPlaceHolder"
runat="server">
<h2>Welcome!</h2>
</asp:Content>
This code generates error when entering page Default.aspx:
Message: Exception of type 'System.Web.HttpUnhandledException' was
thrown.
But after removing asp:Menu from MIMStock.master page is displayed
correctly.
Could you explain me please this phenomena?
I really need to use menu.
/RAM/