Hi team,
i am usng radImage Editor and trying to load jpg image in via ImageFormatProviderManager.import function and getting error that {"The image cannot be decoded. The image header might be corrupted."}.
Same image i can load in image editor demo wpf application given by telerik.
I want to know the reason
code here
string extension = Path.GetExtension(resource).ToLower();
IImageFormatProvider formatProvider = ImageFormatProviderManager.GetFormatProviderByExtension(extension);
//Image image = Image.FromFile(resource);
MemoryStream mmStream = new MemoryStream();
using (FileStream fsStream = File.OpenRead(resource))
{
fsStream.CopyTo(mmStream);
}
return formatProvider.Import(mmStream);
Also attached the exception screen shot and sample Jpg file
Regards
Hema