Compiler error: Type not defined inspite of available class

G

Guest

Hi,
I have been working on ASP.NET 2.0. When I was trying to work with one of
the master pages, I used some classes (.vb files) in App_code directory. When
the application is run, it gives me the following error.

BC40056: Namespace or type specified in the Imports 'XXXX' doesn't contain
any public member or cannot be found. Make sure the namespace or the type is
defined and contains at least one public member. Make sure the imported
element name doesn't use any aliases.

I have verified and the class file is present in the App_code directory with
the namespace defined. Please help me. I am not sure as to what I am doing
wrong.

Rgds.
 
J

Jim Andersen

Jay said:
Hi,
I have been working on ASP.NET 2.0. When I was trying to work with one of
the master pages, I used some classes (.vb files) in App_code directory.
When
the application is run, it gives me the following error.

BC40056: Namespace or type specified in the Imports 'XXXX' doesn't contain
any public member or cannot be found. Make sure the namespace or the type
is
defined and contains at least one public member. Make sure the imported
element name doesn't use any aliases.

I have verified and the class file is present in the App_code directory
with
the namespace defined. Please help me. I am not sure as to what I am doing
wrong.

I get the same error when I work in the VS 2005 IDE. The project compiles
and works OK though, but I get squiggly lines under the "undeclared" method
calls.

I have copied MS Data Access Application Blocks dll to the bin, added a
reference, and at the top of frmTst.aspx.vb, I do "imports
Microsoft.Applicationsblocks.Data", and it looks (and works) great. After
some developing, all of a sudden I see the squiggly lines, and the error you
mention is displayed as a tooltip-text when I hover over the "imports...."
statement.

/jim
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,764
Messages
2,569,566
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top