Delete a file being used by another process July 21, 2023 by Tarik it may be Garbage Collection issue. System.GC.Collect(); System.GC.WaitForPendingFinalizers(); File.Delete(picturePath);