Fix 'Failed to save open documents before committing' error
I would have submitted this to the issue tracker or mailing list, but both were so user-unfriendly that I thought I'd do it here.
The issue (present in 2.1.10129.17) seems to be that, when no documents are open in VS, committing changes results in an error dialog saying "Failed to save open documents before committing." I finally figured out a workaround - open a document before trying to commit.
Shuai Evoque commented
Thanks a lot , It`s Restarting VS.
thanks a lot. I am new to SVN. Restarting VS also works for me
Restarting visual studio resolve the problem
Restarting visual studio fixed it. Just closing and reopening the solution doesn't work. You have to exit the VS and open a new one.
I also got this error.
A couple of forms where deleted, and new forms created with the same name. So I had some files in "new over deleted" state. Maybe that has something to do with the issue ?
At the time the error appeared, no files where open. Opening a file didn't help.
Restarting VS did the trick.
try commit it in file management
Any idea which kind of documents were open within reach of the commit?
We just ask Visual Studio to perform a Save operation on the documents that are open within the commit. This message is the result of a document that says it can't be saved.
So whatever we would commit here might not be what you expect, as the document reports that it has in-memory changes that can't be saved.
Preston McCormick commented
I have been getting the same error lately. In my case the work-around was ineffective.
Restarting Visual Studio fixed it for me
I just restarted VS as opening the document didn't help.