Class defined in relative folder not showing up

  • Thread starter Thread starter Maziar Aflatoun
  • Start date Start date
M

Maziar Aflatoun

Hi everyone,

My web application runs in / however, my administration resides in /admin
folder. Inside my /admin I have a Login.aspx which is used to authenticate
users who use the administration section. I right clicked the /admin in
Visual Studio and Added a new Class (AuthenticateUser). However, in my
Login.aspx I can not use use that class. It gives me the following error
message.

c:\...\admin\Login.aspx.cs(29): The type or namespace name
'AuthenticateUser' could not be found (are you missing a using directive or
an assembly reference?)


Folder structure
/
.../admin -> files Login.aspx and Authenticate.cs

Thank you
Maziar A.
 
This might be overly obvious, but the only thing that comes to my mind is
that your namespaces don't match...
Authenticate.cs will have a namespace of "PROJECT_NAME.Admin" , if you
copied and pasted login.aspx from the root to the admin folder, it's
namespace will just be PROJECT_NAME

Karl
 
Back
Top