Dear list,

I have produced some Microsoft Excel 2003 graphs to use in a LyX
thesis. I'm running LyTeX on Windows XP prof. (Lytex 1.6g = portable
LyX 1.6.3 with portable Texlive 2008) on a USB drive which I plug in
to different computers, at university and at home.

I want to get the graph in the PDF in vector format because of quality
issues. On university computers I have no admin privileges. At home, I
have of course but not with the user account I normally use (because
of safety). I tried the following solutions, suggested on this list
before:
1) Hold shift key and copy graph with edit menu.
2) paste into powerpoint (2003) and save graph as .wmf Windows metafile.
3) import the graph into lyx. Converting it to a loadable format takes forever.
4) pres pdftex button. Now a known message pops up: "Metafile to EPS
Converter: Printer selected not valid." LyX crashes after pressing ok.

Second solution I found was using OLETeX. However it also requires
admin privileges to install a postscript printer.

Third solution is printing the graphs to EPS using PDFCreator (which
is available on all computers) or using Adobe Illustrator (idem). One
disadvantage of these solutions is the margin issue, even if you print
the graph from Excel in a separate window (graph window option) with
margins to zero.

*EDIT / SOLUTION / WORKAROUND *

When writing this question, I solved it myself. I thought it may be
useful to share it with the list. Of course wiki would be better, but
I do not have the time for that.

Requirements: Windows, and working PDFCreator installation
0) Download OLETeX at http://oletex.sourceforge.net/ and unzip on your
portable drive.
1) Run OLETeX's OTEditor.
2) go to Options > Conversion Settings and select PDFCreator (and edit
output directory).
3) paste your Excel graph
4) press the 'convert all objects to EPS' button.

The EPS file is created and can be imported into lyx. On a first
glance, it looks similar to the Excel graph, which is not the case
(e.g. colors) if you copy-paste-save using Illustrator.

A other postscript-aware printer should also work (didn't try). The
following do NOT work: HP Laserjet 1100, HP Deskjet 3500, Microsoft
Office Document Image Writer, Microsoft XPS Document Writer.

This solution should also work for other OLE-objects. like Visio
diagrams. For MS Word text (a function which should not be needed) it
doesn't work. Lyx crashes with some note about multiple dimensions in
the .eps file.

Regards,
Corné

Reply via email to