Explain the differences between Dispose and Finalize() in VB.Net?
S.no | Finalize | Dispose |
---|---|---|
1. | Called by Garbage collector | Handled by IDisposable interface |
2. | Help get rid of unmanaged resources. | Helps in releasing unused resources. |
3. | It is called only when there are no valid references. | Called even if other references are alive. |
BY Best Interview Question ON 12 Feb 2019