Edit

Share via


Compiler Error CS0250

Do not directly call your base class Finalize method. It is called automatically from your destructor.

A program cannot attempt to force cleanup of base class resources.

See Finalizers for more information. This message uses the previous term for finalizer: destructor.

The following sample generates CS0250

// CS0250.cs  
class B  
{  
}  
  
class C : B  
{  
   ~C()  
   {  
      base.Finalize();   // CS0250  
   }  
  
   public static void Main()  
   {  
   }  
}