Originally Posted by Jad
If you feel like doing some programming, you can grab the source code and do a debug while opening your file and see where it breaks in code. I'm guessing its something in the metadata which my parsing can't handle.
Well, after some quick looking around: either Amazon is not including a Database name or they've started butchering the PalmDoc Header in such a way that renders mobi2mobi unable to read the database name. So mobi2mobi pukes on the following command (with some newer Amazon purchases):
mobi2mobi.exe bookname.azw --outfile tmpBook.m2m --savecover cover.m2m --savethumb thumb.m2m
The cover and thumbnail files are properly created but the creation of the temporary outfile (needed by mobi2mobi-gui) fails with the following message: "Can't write a database with no name"
My hackish solution was to include a database name (based on the filename) to the command that mobi2mobi-gui builds in it's btnOpenFile_Click subroutine... which I changed to look like:
BuildBatch(sM2MBatchPath, ((((sMobi2MobiPath & " ") + sOpenedBook & " --databasename " + LeftOf(tbOpenedFile.Text, ".").Substring(0, 31) + " --outfile ") + sTmpBookPathBatch & " --savecover ") + sCoverImagePreviewPathBatch & " --savethumb ") + sThumbnailImagePreviewPathBatch)
I'm sure there's a more elegant solution that would detect whether a database name existed before brutally overwriting it like I'm doing, but it works for me... and Visual Basic just isn't my bag.
For those running into this issue with newer Amazon purchases... if you use the command line version of mobi2mobi to make one simple change... you can then use mobi2mobi-gui to do the rest of the work. Just give the problem book a database name (of any kind) like so:
mobi2mobi.exe originalbookname.azw --databasename some_dummy_name --outfile modifiedbookname.azw
Hope this helps in some way.