Problem with IIS 6

  • Thread starter Thread starter Janaka
  • Start date Start date
J

Janaka

I've recently set up IIS6 on a Windows 2003 server and am trying to migrate
over my ASP.NET applications. I'm not using VS and my page's aspx file
ususally contains something of the following: <%@ Page Src="Default.cs"
Inherits="MyNamespace.Default" %> which worked fine previously. However
now I keep getting the error The base type 'MyNamespace.Default' does not
exist in the source file 'Default.cs'.

Is this a problem with IIS 6?
 
Is this a problem with IIS 6?

No. It has nothing to do with IIS, as the ASP.Net ISAPI does the processing.
My guess is that your CodeBehind page doesn't define the class "Default" as
belonging to a NameSpace. However, you didn't post that code, so that is
merely a guess. To have the CodeBehind which you are not compiling to a DLL
define "Default" as beloning to the NameSpace "MyNameSpace" your code would
have to look something like this:

namespace MyNameSpace
{
public class Default
{
...
}
}

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
http://www.takempis.com
Big Things are made up of
Lots of Little Things.
 
Kevin,

I have got this defined in the codebehind. I think the main thing I should
have mentioned though was that the site works fine locally but it is now
running off a UNC virtual share on another Windows 2003 server. Any ideas?
 
To run web app from UNC share you must do following:
1)Define domain user with appropriate rights to asp.net directories.
2)Create new app pool in IIS6 which uses this account
3)Allow full trust to all dlls which comes from share on IIS PC
HTH
 
Thanks Anatoly,

I've run through these steps and unfortuanately still have the same problem.
Does it matter that we haven't got a domain? I've created a user on both
machines and granted it appropriate permissions.
 
Pay attention on stage 3, which is critical.
Recheck if URL you write in Net Framework configuration EXACTLY the same
like
in IIS in "share located on another computer".
 
Thanks after going through Caspol and setting permissions to the UNC share
its now working
 
Back
Top