Cannot open file for writing error


#1

I frequently get the subject error when trying to write tags to blank fields or end tags that are already in place. The files are mp3 and mp4 files downloaded from public sources like LibriVox.

I have read the previous discussions on this forum about this and have not yet found a simple or consistent method make the problem stop.

I also use the M4A MP3 Converter V4.3 build 1025 software to convert files to and from various formats and to increase the volume so I can hear them better (I have a hearing deficiency and need more playback volume in most cases).

When I use M4A MP3 Converter I can also choose to write tags to the file as it is converted. To use that I have to write all the tags or none of the tags (I can choose to leave the existing tags or leave them blank).

And M4A MP3 will always successfully write tags to the files that Mp3tag will not write to.

So I think that the "..Cannot open file for writing error..." is program bug or program deficiency in Mp3tag. And the blame for this problem, it as it is laid now, on embedded cover art and stuff like that, is incorrect.

Does that sound right? If so, I'll report this as a program bug or design issue. I just wanted to see if other users agreed that it may be a program issue.

Jack


#2

I usually give the advice to modify the workflow as apparently sometimes the Windows explorer is a little nosy and blocks the file as it "feels" that the file is being modified.

So: if you are in the habit of opening files via the Windows Explorer context menu: don't. Instead, use the functions from within MP§tag to access folders. You may use the copy&paste way to get the folder name into MP3tag's address field.
Also, do not let any player be open at the same time if that player has an automatism to update its library. This may interfere with the editing.
If this helps, please let me know.


#3

I had been using only the MP3T functions to open folders with file to tag or re-tag. But I also had been looking at the same folders with Windows Explorer (WE) at some time recently. And I usually have at least 2-3 explorer windows open to other folders/disks/and across the network.

I had not been running a player and did not have one open or running when this happened.

But you have solved my problem for me! Thank you for that.

When I read your post I downloaded the Mp3T 2.55 update and installed that. Then I restarted the computer, did not open any WE windows, and started Mp3T and had no problem writing tags.

When I started WE, but with WE not looking at or having looked at a folder Mp3T had opened yet, I was still able to write tags.

Then I looked at folder that was a parent folder of a folder that I was about to load a mp3 file from. When I opened the subfolder from Mp3T (after having looked at it's parent folder) I got the writing error again. And the error persisted even as I moved WE to look at other folders and even after I closed WE.

And I closed and restarted Mp3T and still got the error (WE is still not open).

I went to the Task Manager, found explorer.exe in the processes list and ended the explorer.exe task. That causes the desktop to go blank (except for the Task Manager) and the Task bar and Tray is gone too. I started explorer.exe as a New Task from the Task Manager's Application tab, that brought my desktop back.

All the apps that had been running were still running when the Task bar and Tray came back and all icons are restored to the desktop as normal.

Then I started Mp3T from a shortcut on the desktop and was again able to write tags.

So I guess you are right about Windows Explorer being the place where the problem is. And closing and restarting explorer.exe from the Task Manager fixes things.

Thanks again for your help. When I have tag writing problems I'll probably just close the exporer.exe process from the Task Manager and restart it. That seems to be a quick and easy way to fix things.

If will help anyone else, the process was:

1 - Right click a blank spot on the Task Bar and click Task Manager

2 - Click the Processes tab, find explorer.exe in the Image Name column, and click on the End Process button. (Desktop goes blank, Task Bar is gone too)

3 - In Task Manager click on Applications tab, type explorer.exe in the Open: window, and click OK. (Desktop and Task Bar return).

Thanks again for the help!

Jack


#4

This is rather drastic and not really advisable.
Usually the indexer tries to get the latest information - so stopping the indexer might be a little less harmful.
Or: configure the WE window in such a way that the WE does not try to update the thumbs.db file (Do not show miniatures).


#5

I don't have an indexer in the task manager, nor can I find a setting for do not show miniatures.

But I'll look into those things...

Thanks,

Jack


#6

If it's a case where there's another process using that file or files then download a program called lockerhunter which enables a context rightclick option on the selected file/s or folder. It will show the processes that are using that file enabling you to unlock the process or even delete the file if needed.

I find it pretty useful for usb eject problems.

Find it here @ http://lockhunter.com


#7

Thanks for the explanation and the link, I'll install that now. ohrenkino said that ending the task on explorer.exe was a bit drastic so I'm sure the lockhunter app will be better way.

Jack


#8

No problem, I forgot to mention it can also kill the processes if you need too but unlocking works 9/10. Great little app :slight_smile: