local namespace & IDE error

R

Random

I'm wondering if anyone has come across this strange behavior in the VS 2005
IDE.

I have several classes in my App_Code directory, organized in folders and
namespace declarations. Some of these classes need to reference other
classes in their procedures. So, simply enough, I include "Imports"
statements so I don't have to use the fully qualified names everywhere in my
code.

The problem I'm encountering is that VS gives me the "Namespace or type
specified in the Imports '...' 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 doesn't use any
aliases."

This only happens in some of the classes, for some of my "Imports"
statements, not all. Very weird. I can't make out any consistency.
 
G

Guest

I ran into this in a VS 2005 Windows application. I resolved it by adding the
application name to the Imports statement, like this:

Imports AppName.SharedCodeClass
 

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

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,236
Members
46,822
Latest member
israfaceZa

Latest Threads

Top