Ethereal-users: Re: [Ethereal-users] win32 printing

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Guy Harris <guy@xxxxxxxxxx>
Date: Wed, 5 Dec 2001 12:23:15 -0800 (PST)
> I see two possibilities:
> a) read that SDK documentation and implement it properly - probably a
> humongeous mess of code, and still requires another application to get the
> pipe to the printer.
> b) on windows send the printed report to a temporary file and then run the
> given application on that file. If the application was "notepad /p" this
> would have the required effect.

c) #ifdef out the code for "print to printer" on Windows
d) on Windows, use the native Windows APIs to print to a printer, rather
   than piping to a command

c) doesn't fix the underlying problem, but at least it keeps Ethereal
from promising what it can't deliver.

d) is probably the best solution, but it requires a significant amount
of work, especially for somebody not familiar with those APIs (a lot of
us aren't, as we're mainly UNIX developers), and might require some
architectural thought to cleanly separate the platform-independent part
of the printing stuff from the platform-dependent part; however, doing
so might also make it possible to use various extant and
under-development UNIX APIs for printing, on platforms on which they're
available (e.g., the CUPS library).