Results 1 to 3 of 3

Thread: inherits screwing up

  1. #1

    Thread Starter
    Frenzied Member Magiaus's Avatar
    Join Date
    Mar 2002
    Location
    swamp land
    Posts
    1,267

    inherits screwing up

    every time I save in vs.net it adds inherits="nsite._default" to the top line. and it causes an error. what can i do?

    Code:
    Server Error in '/nsite' Application.
    --------------------------------------------------------------------------------
    
    Parser Error 
    Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. 
    
    Parser Error Message: Could not load type 'nsite._default'.
    
    Source Error: 
    
    
    Line 1:  <%@ Page Language="vb" AutoEventWireup="false" Codebehind="default.aspx.vb" Inherits="nsite._default" %>
    Line 2:  <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
    Line 3:  <HTML>
     
    
    Source File: D:\temp\iis_outside_empty\nsite\ex\html\nw\default.aspx    Line: 1 
    
    
    --------------------------------------------------------------------------------
    Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573
    Magiaus

    If I helped give me some points.

  2. #2
    C# Aficionado Lord_Rat's Avatar
    Join Date
    Sep 2001
    Location
    Cave
    Posts
    2,497
    It sounds like you need to compile the project file.

    If that's not the case, right click the project file in the solution explorer and choose properties.

    Look for the 'Namespace' text box and take note of the namespace listed. Let's say is was 'Watermellon'.

    Now, view your code-behind page for that aspx file.

    Near the top should be:

    public Class Seeds
    Inherits Page

    The 'Seeds' is the class for that page.

    now, in the PAGE directive, make sure the inherits reads [NameSpace].[ClassName]

    In our example:

    Inherits="Watermellon.Seeds"
    Need to re-register ASP.NET?
    C:\WINNT\Microsoft.NET\Framework\v#VERSIONNUMBER#\aspnet_regiis -i

    (Edit #VERSIONNUMBER# as needed - do a DIR if you don't know)

  3. #3

    Thread Starter
    Frenzied Member Magiaus's Avatar
    Join Date
    Mar 2002
    Location
    swamp land
    Posts
    1,267
    I ended up creating a new project, but if it happens again I'll try and build the project.

    Thanks
    Magiaus

    If I helped give me some points.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width