Skip to main content
Inspiring
December 17, 2017
Answered

unknown or invalid jpeg marker, yet every other program opens the file

  • December 17, 2017
  • 3 replies
  • 4656 views

The subject says it all.  I have several files that I sent to myself from a photo archive site and none of them will open in PS CC, always giving this reason.  But like I said, they all open in every other program, including gmail, Facebook, Microsoft Office, Windows Photos.  So far, only Photoshop doesn't like these files.  In fact here is one of the images, which I see opened just fine here in the Adobe Forum discussion. This looks like a bug to me. You?  If it is, how can I get it entered into the bug list for the next update? (Yes, that is me at the desk, back when I was in 5th grade.  Aren't I adorable?)

This topic has been closed for replies.
Correct answer D Fosse

Yes, this file has a double extension .jpg.png. It's a PNG and it opens just fine in Photoshop here.

I think you have this problem because you have Windows set to hide extensions (and thus .jpg becomes the effective extension). Change that policy in Folder Options, then fix the extension.

3 replies

jazzwilliam
Participating Frequently
December 29, 2017

Yes you need to change to change the file extensions. Go to the file explorer and Under the View tab, deselect the checkbox next to “Hide extensions for known file types” and then click OK.

You can also change the file extension to another file format. For instance, convert a JPEG (.jpeg or .jpg) file extension to a Bitmap file (.bmp)

If there is a file corruption issue then get repair tool, like Stellar Phoenix JPEG Repair.

D Fosse
D FosseCorrect answer
Community Expert
December 17, 2017

Yes, this file has a double extension .jpg.png. It's a PNG and it opens just fine in Photoshop here.

I think you have this problem because you have Windows set to hide extensions (and thus .jpg becomes the effective extension). Change that policy in Folder Options, then fix the extension.

bozitoAuthor
Inspiring
December 17, 2017

Yes, the correct answer was to change the extension to PNG and thank you!  But I DO have my file browser set to display extensions and it does not show the png.jpg extension that you indicated.  BTW, the file name that appears when I hover over the image in my email is JPG.  So the wrong extension was applied when I chose Share this image from the archive site.

So one questions remains.  Why is PS the only program out there that would not open the file when it had the .jpg extension?  Granted, it is not a JPG but EVERY OTHER program seems to figure it out. Bug or feature?

Thanks again for the replies.

bozitoAuthor
Inspiring
December 18, 2017

  wrote

PS could very easily determine that the file is a PNG masquerading as a JPG

In my opinion, and I am not an Adobe employee, it is the responsibility of the person naming the files to use proper file names, not the responsibility of an application to try to figure it out.  Using more than one "." in a file name is not proper file naming.


The file was always named with only one extension (.JPG).  On the original site, in the email in which I sent it to myself, and on my computer hard drive. The original email is in fact a JPG and if I had been on my laptop instead of my Pixel phone when I found it, and had simply chosen Save This Image from the right-click context menu, I would have received a valid JPG   However, I was browsing with my Pixel phone and sent the image to myself so I could have it on my laptop. It was the process of sending it to myself that the image was inexplicably converted to a PNG. But the file name and extension were never changed. At was always named as a JPG and never was a PNG added to the file name, regardless of what someone else here stated.  I opened the email on my laptop and clicked the download icon, which downloaded the image to my hard drive, again preserving the original name and extension.  However, when I tried to open it in PS, I got the offending error message.  And the solution was to change the file name extension to .PNG.  Why Gmail on the Pixel converted a JPG to a PNG without being asked and without changing the file name extension, I do not know.  But that is how all this happened.

But to the point of what PS could and should do, the goal of good software design is to make the user's life easy whenever possible.  I admit that this is probably a rare enough occurrence that it never occurred to the PS developers to have the program try to find out if the file was simply misnamed.  But now that we know that there is a bug in Android (or at least Pixel) Gmail or the Android OS that causes embedded images to be automatically converted to a different file format than they were originally without renaming the file, maybe PS could go the extra step and look for such problems and give an appropriate error message.   It never hurts to give the user as much information as possible and the cost is minimal.  And PS, being the standard that it is, could lead the way in this and a host of other things it is accused of regarding usability.  Just my humble opinion

Community Expert
December 17, 2017

Please change the extension of tha file from .jpg to .png

Community Expert
December 17, 2017

Et voilà!