467,910 Members | 1,522 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 467,910 developers. It's quick & easy.

Compiler error: Type not defined inspite of available class

Jay
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.

Jan 11 '06 #1
  • viewed: 2833
Share:
1 Reply

"Jay" <Ja*@discussions.microsoft.com> skrev i en meddelelse
news:63**********************************@microsof t.com...
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
Jan 26 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Chris Peacock | last post: by
19 posts views Thread by Alf P. Steinbach | last post: by
13 posts views Thread by Eric | last post: by
5 posts views Thread by Lou Pecora | last post: by
reply views Thread by erik.erikson | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.