Upon trying to build the page Default.aspx I get the error:
Error 5 Could not load type 'newVersion_Default'. \server1\d$\newVersion\Default.aspx
The content page is:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="newVersion_Default" MasterPageFile="Main.master" %>
<%@ MasterType VirtualPath="Main.master" %>
<asp:Content id="Content2" contentplaceholderid="mainContent" runat="server">
<h1>Welcome to this Page</h1>
<div class="tabWrapper">
<div class="tab"><a href="#">Home</a></div>
<div class="tab"><a href="#">Tab 2</a></div>
<div class="tab tabSelected"><a href="#">Something Els wef wef w efe</a></div>
<div class="tab"><a href="#">Help!</a></div>
<div class="clear"></div>
</div>
</asp:Content>
And the code behind is empty!
public partial class newVersion_Default : System.Web.UI.Page
{
}
This is probably a newbie error but any help appreciated :)
I can't rebuild the whole project yet because there's some other crap in the folders that is classic ASP which wont build and throw errors, so I have to build each page at a time, will this cause problems?
In case of Web app:
Try use a namespace:
Inherits="MySite.newVersion_Default"
namespace MySite
{
public partial class newVersion_Default : System.Web.UI.Page { }
}
In case of Web site:
Use CodeFile instead of CodeBehind
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With