You need to release the 1.jpg file for writing after BitmapImage started working with another file.
Here is the code
using System; using System.Drawing; //в ссылке System.Drawing using System.Windows.Media.Imaging;//в ссылке PresentationCore namespace Test { class Program { static void Main(string[] args) { BitmapImage img; img = new BitmapImage(new Uri(@"D:\img\1.jpg")); //Несмотря на переход к 2.jpg, файл 1.jpg остается занят img = new BitmapImage(new Uri(@"D:\img\2.jpg")); Image i = Image.FromFile(@"D:\img\3.jpg"); Console.WriteLine(@"Try write in D:\img\1.jpg"); Console.ReadKey(); i.Save(@"D:\img\1.jpg"); } } }