Instructs the garbage collector not to call the object.Finalize method on the specified object.
Type Reason ArgumentNullException obj is a null reference. InvalidOperationException The caller of this method is not the same as the object passed to this method.
The method removes obj from the set of objects that require finalization. obj is required to be the caller of this method.