Photos that I am saving as jpeg are being saved as TextEdit files.

I have tried right clicking the file, choosing Open With, choosing Preview. I click the box to make it the default. It will open it, but it doesn't change the TextEdit status and my other programs won't open it.

iMac 21.5″, macOS 10.15

Posted on Aug 12, 2021 3:35 PM

Reply
Question marked as Top-ranking reply

Posted on Aug 12, 2021 4:02 PM

OK - got it, thanks.


Somehow when you save the file, the .jpg isn't added to the filename. This might be a problem with Photomonky - or is it possible you are not adding .jpg when you write the filename, or deleting the .jpg which is already there?


In any case try renaming the file, and adding .jpg to it (select it in finder, hit enter, hit the right arrow to get to the end of the filename, type .jpg and hit enter again).

Does it work now?

24 replies

Aug 12, 2021 4:50 PM in response to Trishfit

Quick question. When you renamed the extension, did you get a warning message? It doesn't look like you renamed the extension, but rather just added "jpg" to the file.


Go to a finder window.

Then in the menu, Finder > preferences > advanced

Select show all filename extensions



If you change the extension, it will change the program on the right from text document to image, like all the other ones.

Aug 13, 2021 2:24 AM in response to Trishfit

What does mdls say about the the offending file?


...


File suffixes, Creator and Type codes and hexdumps:


1. File suffix. Later OSX/macOS versions no longer recognize the old four letter "Type and Creator" codes but rely on the dumber file suffixes like .doc.


mdls [file]


Old Word .doc:

kMDItemContentType                     = "com.microsoft.word.doc"


New Word .docx:

kMDItemContentType                     = "org.openxmlformats.wordprocessingml.document"


However, if the suffix happens be wrong (.doc instead of .docx etc), then it is reported wrong there.


If the file has no suffix, macOS uses an Unix EXEC icon that means, "I have no idea what this file is."


2. File Type and Creator. Earlier Mac Systems 0-9 used Type and Creator codes that later OSX/macOS versions no longer recognize:


mdls test.doc
kMDItemFSCreatorCode                   = "MSWD"
kMDItemFSTypeCode                      = "W6BN"


Some applications might still insert them but LibreOffice 7 leaves them blank for .doc and .docx:


mdls LibreOffice7.doc
kMDItemFSCreatorCode                   = ""
kMDItemFSTypeCode                      = ""


3. If the file suffix happens to be wrong or it does not have it, you can use xxd to check the the first four bytes hex dump of a file:


A Word .doc file:

xxd -l 4 -p doc.doc  
d0cf11e0


A Word .docx file:

xxd -l 4 -p docx.docx 
504b0304


For example, an old MacWrite 4.5 file with has Creator/Type MACA/WORD:


mdls file         
kMDItemFSCreatorCode                   = "MACA"
kMDItemFSTypeCode                      = "WORD"

Or:
xxd -l 4 -p file 
0006003a


Some 3rd party GUI utilities like FileBuddy could be used to modify Creator/Type info.


Credits to VikingOSX for this info:


https://discussions.apple.com/thread/253009587


See also:


https://en.wikipedia.org/wiki/Creator_code

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Photos that I am saving as jpeg are being saved as TextEdit files.

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.