explicitly refer to the a class without a namespace in C#

Posted by JoelFan on Stack Overflow See other posts from Stack Overflow or by JoelFan
Published on 2010-05-04T18:03:49Z Indexed on 2010/05/04 18:08 UTC
Read the original article Hit count: 238

Filed under:
|
|
|

The code I'm working with has a class called Environment that is not in any namespace. Unfortunately if I am in a class that imports the System namespace, there is no way to refer to the custom class called Environment. I know this was an unfortunate choice and should be refactored, but is there any way I can explicitly refer to the conflicting class?

In C++ it seems the way to do this is by using ::, and in Java there is something called global:: How do I do it in C#?

© Stack Overflow or respective owner

Related posts about c#

Related posts about .NET