Re: truncated File -> Save As -> HTML conversion problem
- To: mathgroup at smc.vnet.net
- Subject: [mg79307] Re: truncated File -> Save As -> HTML conversion problem
- From: David Reiss <dbreiss at gmail.com>
- Date: Tue, 24 Jul 2007 06:04:07 -0400 (EDT)
- References: <f81mnh$m0s$1@smc.vnet.net>
(M 6) In[26]:= $Version (M 6) Out[26]= "6.0 for Mac OS X x86 (32-bit) (June 19, 2007)" I find the following: If I execute Export[ "/Users/dreiss/Desktop/chris/test.html", CreateWindow@ DocumentNotebook[ Table[TextCell[ToString@i, "Text"], {i, 1, 1000}]], "HTML"] then the exported html file is complete. However, if I create the notebook CreateWindow@ DocumentNotebook[Table[TextCell[ToString@i, "Text"], {i, 1, 1000}]] and then use the File>Save As menu command, and save as html, the resulting html file is incomplete. The number of cells that it achieves converting to html varies each time I try it, but is around 600. Some other comments. If I use the SaveAs html menu item, and then attempt to save the notebook again as html over the original file, mathematica tells me that Export (which, of course is behind the Save As command) cannot open the html file that I am trying to save to. If one goes to that file, deletes it (ie throws it into the trash) and then tries to empty the trash, the OS tells one that the file is stil in use. Aparently Mathematica still has the file open and so, the OS lets us know that it is still in use. This is an old old bug that I think(but am not sure) that I reported somewhere in prehistory. The File>Save AS>html approach to html conversion appears to not properly dispose of its connection to the file that it is exporting to. So, perhaps these multiple issues are connected in some way. Since WRI reads these postings very diligently, I will assume that this is a bug report and not submit it through ohter venues. I think that the lesson here is that for real production work, one should use Export directly rather than the less versatile menu command approach. --David A WorkLife FrameWork The first Mathematica-6 compatible add on http://scientificarts.com/worklife Chris Chiasson wrote: > I have run across some odd behavior. When a notebook of any type is > above a certain length or size, the HTML conversion is just truncated. > This happens in V6, not V5. It *doesn't matter what version wrote the > notebook*, if V6 saves it to HTML and the notebook is long, the file > is truncated: > > Simple Test Notebooks: > > http://test.chris.chiasson.name/fuel-cell-electrochemistry/automaticnumbering.nb > > http://test.chris.chiasson.name/fuel-cell-electrochemistry/automaticnumberingV5.nb > > > If yours doesn't truncate the html file, try increasing the number of > cells in the notebook (easy to do in automaticnumberingV5.nb b/c of > Print statement and Do loop). > > My server computer's motherboard is fried, so I haven't had a chance > to try this on another machine. Note also that, to help isolate the > problem, I uninstalled Mathematica 6, deleted my C:\Documents and > Settings\Chris\Application Data\Mathematica directory, reinstalled > Mathematica 6 and rebooted. The problem still persists. > > Is anyone else able to reproduce this? It is quite distressing... > > I'm running 6.0.0 for students on Windows XP SP 2. > > -- > http://chris.chiasson.name/