myImage.Source = new BitmapImage(new Uri("/folder/imagename.png", UriKind.Relative));
This used to work in WPF applications for Windows 7, but there, in Windows 8, I got an error
Thanks in advance.
The Image.Source property is of type ImageSource. Therefore, try the following example:
myImage.Source = "/YourApplicationName;component/folder/imagename.png";