Make sure that the class defined in this code file matches the 'inherits' attribute
Hi there,
I have created .aspx page using templates and put code behind page and inherits as well.
i ma getting below error on page
Make
sure that the class defined in this code file matches the 'inherits'
attribute, and that it extends the correct base class (e.g. Page or
UserControl).
Description: An
error occurred during the compilation of a resource required to service
this request. Please review the following specific error details and
modify your source code appropriately.
Compiler Error Message: ASPNET: Make sure that the
class defined in this code file matches the 'inherits' attribute, and
that it extends the correct base class (e.g. Page or UserControl).
Source Error:
Line 8: Line 9: Line 10: public partial class Login : System.Web.UI.Page Line 11: { Line 12: LeadSale ls = new LeadSale();
Hi I have the same issue. I am getting this error:
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: ASPNET: Make sure that the class defined in this code file matches the 'inherits' attribute, and that it extends the correct base class (e.g. Page or UserControl).
Source Error:
Line 5: using System.Web.UI.WebControls;
Line 6: using System.Net.Mail;
Line 7: public partial class SignUp : System.Web.UI.Page Line 8: {
Line 9: protected void Btn_SignUp_Click(object sender, EventArgs e)
I have an existing website I am migrating to Umbraco and there is a page to sign up to an email list. I already built the code behind file and it worked fine outside Umbraco. I have read many articles on the forum about code behind but don't find exactly the answer I need, maybe due to my inexperience with Umbraco.
I have created a template for the Signup.aspx page and first line is:
I have placed the code behind file SignUp.aspx.cs in the masterpages folder of the site root.
The first few lines of code for Signup.aspx.cs is as follows:
using System; using System.Collections.Generic; using System.Text; using System.Net; using System.Web.UI.WebControls; using System.Net.Mail; public partial class SignUp : System.Web.UI.Page { protected void Btn_SignUp_Click(object sender, EventArgs e) {
Can anyone provide guidance - why doesn't this work within Umbraco templates. Is it something to do with it all being wrapped with <%@ Master Language="C#" MasterPageFile="~/umbraco/masterpages/default.master" AutoEventWireup="true" %> ?
Make sure that the class defined in this code file matches the 'inherits' attribute
Hi there,
I have created .aspx page using templates and put code behind page and inherits as well.
i ma getting below error on page
Make sure that the class defined in this code file matches the 'inherits' attribute, and that it extends the correct base class (e.g. Page or UserControl).
i am using .net 3.5 and site is hosted on IIS 7.
hope it helps
Thanks
Hi there,
see below page where i am getting error
http://www.leadsale.co.uk/Login.aspx
Thanks
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: ASPNET: Make sure that the class defined in this code file matches the 'inherits' attribute, and that it extends the correct base class (e.g. Page or UserControl).
Source Error:
Hi I have the same issue. I am getting this error:
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: ASPNET: Make sure that the class defined in this code file matches the 'inherits' attribute, and that it extends the correct base class (e.g. Page or UserControl).
Source Error:
Line 5: using System.Web.UI.WebControls; Line 6: using System.Net.Mail; Line 7: public partial class SignUp : System.Web.UI.Page Line 8: { Line 9: protected void Btn_SignUp_Click(object sender, EventArgs e)
I have an existing website I am migrating to Umbraco and there is a page to sign up to an email list. I already built the code behind file and it worked fine outside Umbraco. I have read many articles on the forum about code behind but don't find exactly the answer I need, maybe due to my inexperience with Umbraco.
I have created a template for the Signup.aspx page and first line is:
<%@ Master Language="C#" MasterPageFile="~/masterpages/Master.master" AutoEventWireup="true" CodeFile="SignUp.aspx.cs" Inherits="SignUp" %>
I have placed the code behind file SignUp.aspx.cs in the masterpages folder of the site root.
The first few lines of code for Signup.aspx.cs is as follows:
using System;
using System.Collections.Generic;
using System.Text;
using System.Net;
using System.Web.UI.WebControls;
using System.Net.Mail;
public partial class SignUp : System.Web.UI.Page
{
protected void Btn_SignUp_Click(object sender, EventArgs e)
{
Can anyone provide guidance - why doesn't this work within Umbraco templates. Is it something to do with it all being wrapped with
<%@ Master Language="C#" MasterPageFile="~/umbraco/masterpages/default.master" AutoEventWireup="true" %> ?
Any guidance much appreciated.
See here: http://our.umbraco.org/forum/using/ui-questions/39127-Importing-aspxcs-files-into-Umbraco
is working on a reply...