Thank you Joseph Delaney for posting such clear and easy to follow instructions. The fix worked perfectly for me and I am able to sync again, after having to uncheck sync photos in the iTunes settings for my iPhone to get it to sync at all. What an obscure problem! Who would have thought? Credit also to Andrew Patterson for his patience in finding the root cause.
Just updated to ML v8.2.2 and and iPhoto v9.4. Immediately, I was unable to sync in the same fashion that all have been describing here. Tried some of the possible fixes. Have decided to wait for Apple to solve the problem. Have just turned off syncing of photos on my iPad 3, iPhone 4S, and iPod 4 for now so that I can complete a sync.
Sent in a bug report to Apple to help fuel the fires of a speedy update and repair.
Some times I wonder how problems like this sneak through the pipeline, but...
Thanks to all the posters who spent so much time offering help. You are all the best.
-- This problem is not just for iPhoto 9.4! --
Thank you for this fix. Worked great for me, with ONE KEY VARIATION.
I'm still using iPhoto 9.3.2, and had the problem when I tried to sync my new iPhone 5. Suddenly the Select Albums option was greyed out (and it suddenly was for my older iPhone 4, too. I have no idea why that one suddenly changed)
The solution was similar but different: I searched through AlbumData.XML for the ampersand with a space, and found nothing. (I have no slideshows). So I searched instead for only ampersands WITHOUT the space, and found a few photo albums with an ampersand in the name (like "Bob & Susan Vacation" or whatever). I changed those to "and" right there in the text editor. Saved the file. Quit. Restarted iPhoto and viola: I could sync again.
Worked for me. Anyone else?
Thanks for all the help
I don't know why I didn't think of this earlier, but there is a very simple way to find the song or album that is causing the problem. Use Safari.
1. Go to your home folder, into the "Pictures" folder, and right-click on your iPhoto Library.
2. Choose "Show Package Contents"
3. Find the "AlbumData.xml" file - and here's the new part - drop the file on Safari.
What you'll see is an error message in a big pink box, and then a very messy page of gobbledygook. That's OK.
4. Scroll to the very bottom of the page, and read the last line or two - you should see the name of the Album where the problem is.
For example, this is the last line of what I get when I do this -
AlbumName Animals Album Type Regular GUID 7DKKA3OJQEa8xdhBCq9uKQSongPath
which let's me know that the album named "Animals" is the one I need to change. It stops when it runs into the error (in the "song path" - that includes the artist, album and song name).
I can then go into iPhoto, click the "Animals" Photo Album, click the "sildeshow" button, and set the music to anything that does not have an ampersand, quotation mark, apostrophe, or less than/greater than signs in the name, album, or artist.
Safari won't show you all the problems, it will stop at the first one it finds. But if you fix the firs problem, then repeat the procedure, you'll find the next, so just keep repeating until they're all gone (no more pink error box, and nicely indented list of technical information).
You can use Firefox too (you have to drag the file into an open Firefox window, dragging it onto the icon will not work). But Firefox works a little differently - it will show you the name of the song right away, at the top of the page - but it doesn't show you the name of the album. I think Safari works better, even though it's a little harder to read.
DO NOT EDIT THE XML FILE DIRECTLY!!!!
While it might be OK to do that, it's also highly possible that you'll cause subsequent problems later on down the line. You have no way of knowing how iPhoto and the other iLife apps use that information, so you may cause things to mismatch.
It's much safer to open up iPhoto and make the changes there. And it only takes a second or two longer.
Timco - just wait.
Yesterday (Sept 28) Apple released an update to Aperture (not iPhoto, sadly), and one of the fixes is this:
Improves the reliability of syncing photos to iOS devices via iTunes
So I think we can now all start holding our collective breath - the matching update to iPhoto should be just around the corner.
Just came here to report that Aperture update fixed my photo syncing problems with my iPhone 5 and iPads.
I didn't even think Aperture was an issue since I never selected to sync using aperture. But now my iPhoto options are not grayed out to select partial library options, and the full library sync finally shows my accurate 12.8 gigs of space in the colored device fill bar at the bottom of iTunes sync.