This topic has not yet been rated - Rate this topic

Compiler Error CS0138

A using namespace directive can only be applied to namespaces; 'type' is a type not a namespace

A using directive can only take the name of a namespace as a parameter. For more information, see Namespaces (C# Programming Guide).

The following sample generates CS0138:

// CS0138.cs
using System.Object;   // CS0138
Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ