What is the difference between Finalize() and Dispose() methods?
Muhammad Imran Ansari
Select an image from your device to upload
Hi Muhammad Imran Ansari,
The main difference between dispose() and finalize() is that:
For more details:
Difference Between dispose() and finalize() in C#https://techdifferences.com/difference-between-dispose-and-finalize-in-c-sharp.html
Hope, this will help you
It belongs to IDisposable interface and It belongs to Object class.dispose() must be explicitly invoked by the programmer. In contrast, finalize() method is invoked by the GC before the object is destroyed