Export (0) Print
Expand All
Expand Minimize

Compiler Error CS0187

Visual Studio .NET 2003

No such operator 'operator' defined for type 'type'

An operator was used on a type, but was not defined to do so.

The following sample generates CS0187:

// CS0187.cs
class MyClass
{
   public static void Main()
   {
      string someString = "Hello";
      someString++;   // CS0187
   }
}
Show:
© 2014 Microsoft