I have a serious question for you guys. I am working on a project that has hundreds of classes. Why cant i access all classes if i want to create an object of that class.
For example: I have Class A, B and C.
In Page 1, i can create an object of A and B but not C. When i try to type in Class C, the intellisense does not work. I need to access class C to get some of the functions used in it.
What can i do to get access to create objects of class C??
Chances are you’re missing either:
usingdirective for the namespace containing class CFor example, to use the
NetworkStreamclass, you’d need a reference to the System.dll assembly, and you’d usually have a using directive like this:in the class that needed to use it. You don’t have to have a
usingdirective – you can specify the full name explicitly – but it’s usually a good idea.Now it’s also possible that class C is internal to the project it’s part of, and you’re in a different project – which means that you don’t have access to it (and you’re not meant to). Or perhaps you’re trying to call a constructor and there aren’t any publicly available ones, for example.