WPF throws “Cannot locate resource” exception when loading the image January 15, 2023 by Tarik In Solution Explorer set the image file’s Build Action property to Resource. Then clean the solution and rebuild it.