K
K Viltersten
I'm using the following setup.
namespace Outer.ProjName {
public class ProjName {...} }
Note that the namespace and the class have the same
name. When i in another class make the call as this:
namespace Outer.SomeStuff {
class Class {
public Class () {
ProjName.ProjName.someMethod();
} } }
It works. But skipping the first "ProjName" and
adding "using Outer.ProjName;" as follows, seems
to confuse C#, as it believes that it's the namespace
i'm referring to, not the class in a namespace that
i've using'ed.
Suggestions? The only solution i see is not to use
the same name for the namespace and the
contained class. Is there anything more neat?
namespace Outer.ProjName {
public class ProjName {...} }
Note that the namespace and the class have the same
name. When i in another class make the call as this:
namespace Outer.SomeStuff {
class Class {
public Class () {
ProjName.ProjName.someMethod();
} } }
It works. But skipping the first "ProjName" and
adding "using Outer.ProjName;" as follows, seems
to confuse C#, as it believes that it's the namespace
i'm referring to, not the class in a namespace that
i've using'ed.
Suggestions? The only solution i see is not to use
the same name for the namespace and the
contained class. Is there anything more neat?